How to get the raw streaming URL from an iHeartRadio station

Create a simple script

I called mine iheart.sh

#!/usr/bin/env bash

wget -O - "$1" | grep initialProps | sed 's/\,/\n/g' | grep stream | cut -f2- -d':' | cut -f2 -d'"' | grep http | sort | uniq

Visit radio station page

  1. Example visit B97
  2. Click on share icon (square box with up arrow to the right of Connect)
  3. Copy entire URL, in this case https://www.iheart.com/live/b97-2609/?embed=true
  4. From CLI run your script. iheart.sh https://www.iheart.com/live/b97-2609/?embed=true

Your output should include:

https://i.iheart.com/v3/re/assets.streams/659dc2f63ec100941ae8f5b9
https://stream.revma.ihrhls.com/zc2609
https://stream.revma.ihrhls.com/zc2609/hls.m3u8
http://stream.revma.ihrhls.com/zc2609

Note, not every URL in your output will be a streaming URL. Usually the bottom three work. Your mileage may vary.