# \[WS\] Genius (Lyrics)

**URL:** <https://community.mp3tag.de/t/ws-genius-lyrics/52933>\
**Category:** Web Sources Scripts\
**Created:** [April 22, 2021, 10:03am UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933 "2021-04-22T10:03:55Z")\
**Posts on this page:** 20\
**Page:** 3

<div class="post-metadata">

**Author:** ![poster](https://community.mp3tag.de/user_avatar/community.mp3tag.de/poster/32/4881_2.png) [@poster](https://community.mp3tag.de/u/poster)\
**Post date:** [September 1, 2022, 11:49am UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/43 "2022-09-01T11:49:56Z")

</div>

> [@bugzero](#):
>
> Additional tags are: `TITLE, COVERURL, GENIUS_URL`.

Is it possible to change the script to fetch the writer of the song too?  
This information is **not always** included on Genius **but often** it is displayed in the credits-section.

---

<div class="post-metadata">

**Author:** ![R2S2](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/r/7c8e57/32.png) [@R2S2](https://community.mp3tag.de/u/R2S2)\
**Post date:** [January 16, 2023, 9:40pm UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/44 "2023-01-16T21:40:48Z")

</div>

@bugzero: thanks for your great script

I got it running. However it seems to be necessary that each song is processed one by one with it.  
Maybe I missed it or it is a noob question, but is there a possibility to automate obtaining the lyrics using your script by executing it in scope of an action list?

---

<div class="post-metadata">

**Author:** ![andrewb0922](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/a/848f3c/32.png) [@andrewb0922](https://community.mp3tag.de/u/andrewb0922)\
**Post date:** [February 20, 2023, 9:32am UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/46 "2023-02-20T09:32:07Z")

</div>

I use Power Automate.  
An automation tool MS made that can do anything you desire. It might take some learning to use it but it is definitely worth it.

---

<div class="post-metadata">

**Author:** ![kein\_schwabe](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/k/7ab992/32.png) [@kein\_schwabe](https://community.mp3tag.de/u/kein_schwabe)\
**Post date:** [February 21, 2023, 5:38pm UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/47 "2023-02-21T17:38:22Z")

</div>

i also get this error, just found and "installed" the script  
 ![2023-02-21_183146](https://community.mp3tag.de/uploads/default/original/2X/d/d409c0356b93f909e6f1d37cd03a9edd2836703e.jpeg)

---

<div class="post-metadata">

**Author:** ![andrewb0922](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/a/848f3c/32.png) [@andrewb0922](https://community.mp3tag.de/u/andrewb0922)\
**Post date:** [April 6, 2024, 9:03am UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/48 "2024-04-06T09:03:30Z")

</div>

Thanks for the update!! Works like a charm. I've been customizing the script here and there but got stuck

I've added

outputto "TEMP\_Comment"  
say "Composer: "  
json\_select\_many "producerArtists" "name" ", "  
sayrest  
say "\u000d\u000a"  
say "Lyricist: "  
json\_select\_many "writerArtists" "name" ", "  
sayrest  
say "\u000d\u000a"  
say "Featuring: "  
json\_select\_many "featuredArtists" "name" ", "  
sayrest

so in Comment tag it inputs  
Composer: Artist 1  
Lyricist: Artist 2  
Featuring: Artist 3

What I want to do is that when there is no element skip it altogether.

So rather than  
Composer: Artist 1  
Lyricist: Artist 2  
Featuring:

I want it to be

Composer: Artist 1  
Lyricist: Artist 2

but no matter how I phrase the if statement I couldn't get there.

---

<div class="post-metadata">

**Author:** ![andrewb0922](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/a/848f3c/32.png) [@andrewb0922](https://community.mp3tag.de/u/andrewb0922)\
**Post date:** [April 7, 2024, 12:36pm UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/49 "2024-04-07T12:36:22Z")

</div>

NVM i've figured it out myself.  
I was trying to learn the functions for the script and searched for documentations but I couldn't find any. Can you link me any source to learn?

---

<div class="post-metadata">

**Author:** ![LyricsLover](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/c6cbf5/32.png) [@LyricsLover](https://community.mp3tag.de/u/LyricsLover)\
**Post date:** [April 7, 2024, 12:49pm UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/50 "2024-04-07T12:49:06Z")

</div>

> [@andrewb0922](#):
>
> Can you link me any source to learn?

> **[Developing Tag Sources – Mp3tag Documentation](https://docs.mp3tag.de/tag-sources/development/)**
>
> Documentation for developers describing the Web Source file format and the parser language used for extracting metadata from online sources. Mp3tag is the universal Tag Editor.

In addition: Look at the existing Web Source Scripts.

---

<div class="post-metadata">

**Author:** ![andrewb0922](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/a/848f3c/32.png) [@andrewb0922](https://community.mp3tag.de/u/andrewb0922)\
**Post date:** [April 7, 2024, 1:05pm UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/51 "2024-04-07T13:05:11Z")

</div>

Thank you so much 🙂  
As a novice in programming, trying to reverse engineer out of thin air was such a headache

---

<div class="post-metadata">

**Author:** ![chero97](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/c/278dde/32.png) [@chero97](https://community.mp3tag.de/u/chero97)\
**Post date:** [September 13, 2024, 9:22am UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/52 "2024-09-13T09:22:17Z")

</div>

The multitagging script is not working for me it's tagging single files but then it stops and i have to relaunch the script.

Does anyone have an idea of how to fix it or at least stop it from having to be relaunched, so its at least usable as a faster tagging tool?

---

<div class="post-metadata">

**Author:** ![chero97](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/c/278dde/32.png) [@chero97](https://community.mp3tag.de/u/chero97)\
**Post date:** [October 3, 2024, 7:18pm UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/53 "2024-10-03T19:18:00Z")

</div>

Firstly I found a method to make the autohotkey script work semioptimally, you still have to restart the script every ten uses but that still more reliable than what I could do with it beforehand.

; Multi Tag Lyrics v0.11, designed to be used with "MP3TAG v3.07" and "[WS] Genius (Lyrics) v0.21" ([[WS] Genius (Lyrics)](https://community.mp3tag.de/t/ws-genius-lyrics/52933))  
; AutoHotKey script written by sruxd ([https://community.mp3tag.de/u/sruxd](https://community.mp3tag.de/u/sruxd))  
; You can use this code for free under the MIT License

#MaxThreadsPerHotkey 250  
SetTitleMatchMode, RegEx ; use regex to detect which window is active

#IfWinActive ^Mp3tag.\*?\ ; only enable hotkey in main window mp3tag; window title must start with "Mp3tag" and end with the "" of the path name  
^m:: ; hotkey = CTRL + G  
{  
send, {CTRL UP}{ALT} ; press ALT to enter menu, press arrow right to select the tag sources  
loop 5 {  
send, {RIGHT}  
}  
send, {ENTER}

```
loop 8 { ; press down until genius scrips
	send, {DOWN}
}
send, {ENTER}

send, {DOWN} ; choose 3rd script, seems most reliable
send, {ENTER}
send, {ENTER}
send, {ENTER}

WinWaitActive .*lyrics$ ; wait till message box with search suggestion appears
send, {ENTER}
WinWaitNotActive .*lyrics$

WinWaitNotActive ^Mp3tag.*?\\	; wait till next window opens
if WinActive("^Mp3tag v\d+\.\d+$")	; detect if error window is shown
{
	send, {RIGHT} ; select "cancel"
	send, {ENTER} ; confirm "cancel"
}
else
{
	send, {ENTER} ; auto confirm suggested string
	send, {ENTER} ; auto confirm whatever was found
	WinWaitNotActive ^Mp3tag.*?\\
}

WinWaitActive ^Mp3tag.*?\\ ; ensure main window is open
send, {DOWN} ; jump to next entry in list

```

}  
Reload

Secondly the json part of the genius import script has stopped working for some reason.  
The only metadata it still returns is the genius URL. Is anyone else experiencing this issue or is this an issue on my end. If so does anyone have a fix for this issue?

---

<div class="post-metadata">

**Author:** ![Ouargui](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/f17d59/32.png) [@Ouargui](https://community.mp3tag.de/u/Ouargui)\
**Post date:** [October 6, 2024, 8:36am UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/54 "2024-10-06T08:36:10Z")

</div>

yes, json version isn't working

can someone fix it?

---

<div class="post-metadata">

**Author:** ![Ouargui](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/f17d59/32.png) [@Ouargui](https://community.mp3tag.de/u/Ouargui)\
**Post date:** [October 7, 2024, 7:31am UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/55 "2024-10-07T07:31:42Z")

</div>

hello again, to whom it may concern i've managed to miraculously make it work:

the issue was here

```auto
regexpReplace "(?i).* __PRELOADED_STATE__.+parse\('(.+)'\);\s*?window.*" "$1"

```

the not so creative alternative that i came up with:

```auto
regexpreplace "(.*\"body\":\{\"html\":\")(.*)(\",\"children\".*)" "$2"

```

what's more is that i couldn't work out the JSON function for the life of me, so i've just used regexpreplace instead, the file attached is my version that fetches the lyrics only, which is better than nothing i guess

[BGenius Album Artist.src](https://community.mp3tag.de/uploads/short-url/3nOm24PKyqQ3wUbdhdi5LBjPmjt.src) (2.7 KB)

---

<div class="post-metadata">

**Author:** ![bugzero](https://community.mp3tag.de/user_avatar/community.mp3tag.de/bugzero/32/10350_2.png) [@bugzero](https://community.mp3tag.de/u/bugzero)\
**Post date:** [October 7, 2024, 6:46pm UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/56 "2024-10-07T18:46:21Z")

</div>

Thanks for the advise.

Sorry for solving the problem so late, I've had a lot of work these days.

You can download the version 0.51 and test it.

---

<div class="post-metadata">

**Author:** ![Ouargui](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/f17d59/32.png) [@Ouargui](https://community.mp3tag.de/u/Ouargui)\
**Post date:** [October 9, 2024, 10:51am UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/57 "2024-10-09T10:51:41Z")

</div>

thank you so much, it's working well now

---

<div class="post-metadata">

**Author:** ![Markus1](https://community.mp3tag.de/user_avatar/community.mp3tag.de/markus1/32/8927_2.png) [@Markus1](https://community.mp3tag.de/u/Markus1)\
**Post date:** [January 16, 2025, 3:26pm UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/58 "2025-01-16T15:26:42Z")

</div>

Is anyone still using this plugin? Right now it does not work for me, all I get when trying to fetch is _\<Error\>_

Example request:  
[debug-output.rar](https://community.mp3tag.de/uploads/short-url/boCO5ueRPxxMrcrHVxPjbdCy59t.rar) (167.8 KB)

Fixed for me by adding

```auto
regexpreplace "<div\s+data-lyrics-container=\"true\"[^>]+?>(.+?)<\s*\/div\s*>" "<lyrics:start>$1<lyrics:end>"

```

---

<div class="post-metadata">

**Author:** ![bugzero](https://community.mp3tag.de/user_avatar/community.mp3tag.de/bugzero/32/10350_2.png) [@bugzero](https://community.mp3tag.de/u/bugzero)\
**Post date:** [January 17, 2025, 7:58am UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/59 "2025-01-17T07:58:46Z")

</div>

> [@Markus1](#):
>
> `<div\s+data-lyrics-container=`

Hello Markus,

Are you using HTML or JSON version?

I'm getting message when I select HTML version.  
A long time ago, I switched to the JSON version, leaving the HTML version untouched, as it provides more tags and a better format for lyrics.

Maybe in next version I will remove HTML version.

---

<div class="post-metadata">

**Author:** ![Markus1](https://community.mp3tag.de/user_avatar/community.mp3tag.de/markus1/32/8927_2.png) [@Markus1](https://community.mp3tag.de/u/Markus1)\
**Post date:** [January 20, 2025, 4:22pm UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/60 "2025-01-20T16:22:56Z")

</div>

I'm using the HTML version because the JSON version never worked for me. But I just noticed that I'm using a very outdated mp3tag version. My bad. Will use the JSON version from now on. Thanks for the hint!

---

<div class="post-metadata">

**Author:** ![R2S2](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/r/7c8e57/32.png) [@R2S2](https://community.mp3tag.de/u/R2S2)\
**Post date:** [June 3, 2025, 2:42pm UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/62 "2025-06-03T14:42:44Z")

</div>

The JSON reply provides Lyrics without linebreaks, the HTML version had the breaks, but currently for me it also does not work.

---

<div class="post-metadata">

**Author:** ![vqla](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/v/cdc98d/32.png) [@vqla](https://community.mp3tag.de/u/vqla)\
**Post date:** [June 5, 2025, 6:12pm UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/63 "2025-06-05T18:12:03Z")

</div>

got this problem, it doesn't seem to form a search url from the title given

 ![SS 2025-06-05 at 23.10.04](https://community.mp3tag.de/uploads/default/original/3X/8/0/80c4b433a2ed1e3acca2e7d20475504ac86119ff.jpeg)  
 ![SS 2025-06-05 at 23.10.09](https://community.mp3tag.de/uploads/default/original/3X/0/3/035d64eb52455d350cd4bc4e164b9c03aee69a79.png)

---

<div class="post-metadata">

**Author:** ![Reason](https://community.mp3tag.de/user_avatar/community.mp3tag.de/reason/32/18761_2.png) [@Reason](https://community.mp3tag.de/u/Reason)\
**Post date:** [August 9, 2025, 2:55am UTC](https://community.mp3tag.de/t/ws-genius-lyrics/52933/64 "2025-08-09T02:55:56Z")

</div>

Hello, I am getting a 404 from your generously provided [Genius.com](http://Genius.com) script. It downloaded the lyrics for two tracks but then started to immediately return the error.

MP3Tag 3.30

Genius WSS 0.52

 ![image](https://community.mp3tag.de/uploads/default/original/3X/2/e/2e94ae5516be016ac6e193908db62bb43a076ffb.png)

 ![image](https://community.mp3tag.de/uploads/default/original/3X/9/1/919b8c885a8fc2eeb2b3de249f3286eba31503de.png)

I am able to navigate to the website and search for the lyrics and copy/paste manually, so the site is not down.

Any idea how to fix this? The fact that it worked twice makes me think they are blocking people from scraping their site somehow, but I don’t know that.

[Previous page](https://community.mp3tag.de/t/ws-genius-lyrics/52933.md?page=2)

[Next page](https://community.mp3tag.de/t/ws-genius-lyrics/52933.md?page=4)
