Spotify Account Creator


New Member
Hello guys,

I built this out of pure boredom and thought i would share it with you all - Its a total PoC. But it works!

function get_cookie() 
    $ch = curl_init(''); 
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); 
    curl_setopt($ch, CURLOPT_HEADER, 1); 
    $result = curl_exec($ch); 
    preg_match('/^Set-Cookie:\s*([^;]*)/mi', $result, $m); 
    parse_str($m[1], $cookies); 
    return $cookies["sp_csrf"]; 

function randomPassword() { 
    $alphabet = "abcdefghijklmnopqrstuwxyzABCDEFGHIJKLMNOPQRSTUWXYZ0123456789"; 
    $pass = array(); //remember to declare $pass as an array 
    $alphaLength = strlen($alphabet) - 1; //put the length -1 in cache 
    for ($i = 0; $i < 8; $i++) { 
        $n = rand(0, $alphaLength); 
        $pass[] = $alphabet[$n]; 
    return implode($pass); //turn the array into a string 

//name generation 
$ext = array('.gov','.be', '.biz', '.ch', '.com', '.co', '', '.de', '.es', '.eu', '.fr', '.gr', '.im', '.info', '.io', '.it', '.lu', '.lt', '.me', '.mobi', '.mx', '.net', '.nl', '.org', '.pro', '.pt', '.re', '.ru', '.se', '.tel', '.tv', '.aero', '.biz', '.com', '.coop', '.info', '.mobi', '.name', '.net', '.org', '.pro', '.tel', '.travel', '.xxx', '.ag', '', '', '.bz', '.ca', '.cc', '.co', '.gd', '.gs', '.gy', '.hn', '.ht', '.la', '.lc', '.ms', '.mx', '.pe', '.pm', '', '.sx', '.tc', '.us', '', '', '', '.vc', '.vg', '.at', '.be', '.cat', '.ch', '', '', '.de', '', '.dk', '.es', '.eu', '', '.fi', '.fr', '', '', '.gg', '.gr', '', '', '', '.im', '.it', '.je', '.li', '.lt', '.lu', '.lv', '.me', '', '.nl', '.no', '', '.nu', '', '.pl', '.pt', '.ro', '.ru', '', '.se', '', '', '', '', '.ru', '', '.af', '.am', '.asia', '.cn', '', '.cx', '.fm', '.hk', '.in', '', '.io', '.jp', '', '', '.ki', '', '.mn',    '.nf', '.nz', '.ph', '.pw', '', '.sb', '.tl', '.tv', '.tw', '.wf', '.ws', '.cm', '.mg', '.mu', '.re', '.sc', '.so', '.tf', '.yt', '.za', '' ); 
$names = array ('tony','lea','mary','bruce','Annabel', 'Asher', 'Atticus', 'August', 'Butch', 'Clementine', 'Daisy', 'Dashiell', 'Delilah', 'Dexter', 'Dixie', 'Duke', 'Edie', 'Elvis', 'Flora', 'Frances', 'Frank', 'Georgia', 'Gus', 'Hazel', 'Homer', 'Hopper', 'Hudson', 'Hugo', 'Ike', 'India', 'Ione', 'Iris', 'Isla', 'Ivy', 'June', 'Kai', 'Kingston', 'Lennon', 'Leonora', 'Leopold', 'Levi', 'Lila', 'Lionel', 'Lola', 'Luca', 'Lulu', 'Magnus', 'Mamie', 'Matilda', 'Millie', 'Milo', 'Minnie', 'Moses', 'Olive', 'Orson', 'Oscar', 'Otis', 'Pearl', 'Piper', 'Poppy', 'Ray', 'Roman', 'Romy', 'Roscoe', 'Ruby', 'Rufus', 'Sadie', 'Scarlett', 'Sebastian', 'Stella', 'Stellan', 'Sullivan', 'Talullah', 'Theo', 'Violet'); 
$names2 = array('gordon','wayne','gates','clinton','washington','carlson','wolowitz','stark','simpson','Jacka','Hackett','Buzzigoli','Mossmann','Hamm','Solano','Huntington','Fath','Goncalves','Decristoforo','Ellsworth','Alonsogarcia','Bullough','Bankhead','Swank','Rickels','Book','Dicks','Guo','Margolin','Mcdermott','Ciannavei','Buccianti','Lamb','Rzepka','Lovegreen'); 
$domain1 = array('Babble', 'Buzz', 'Blog', 'Blue', 'Brain', 'Bright', 'Browse', 'Bubble', 'Chat', 'Chatter', 'Dab', 'Dazzle', 'Dev', 'Digi', 'Edge', 'Feed', 'Five', 'Flash', 'Flip', 'Gab', 'Giga',  'Inno', 'Jabber', 'Jax', 'Jet', 'Jump', 'Link', 'Live', 'My', 'N', 'Photo', 'Pod', 'Real', 'Riff', 'Shuffle', 'Snap', 'Skip', 'Tag', 'Tek', 'Thought', 'Top', 'Topic', 'Twitter', 'Word', 'You', 'Zoom'); 
$domain2 = array('bean', 'beat', 'bird', 'blab', 'box', 'bridge', 'bug', 'buzz', 'cast', 'cat', 'chat', 'club', 'cube', 'dog', 'drive', 'feed', 'fire', 'fish', 'fly', 'ify', 'jam', 'links', 'list', 'lounge', 'mix', 'nation', 'opia', 'pad', 'path', 'pedia', 'point', 'pulse', 'set', 'space', 'span', 'share', 'shots', 'sphere', 'spot', 'storm',  'ster', 'tag', 'tags', 'tube', 'tune', 'type', 'verse', 'vine', 'ware', 'wire', 'works', 'XS', 'Z', 'zone', 'zoom'); 
$separators = array('-','_','.',''); 

$randomExt = $ext[0]; 
$randomName = $names[0]; 
$randomName2 = $names2[0]; 
$randomSeparator = $separators[0]; 
$randomDomain1 = $domain1[0]; 
$randomDomain2 = $domain2[0]; 

$mail = $randomName.$randomSeparator.$randomName2.'@'.$randomDomain1.$randomDomain2.$randomExt; 
$username = $_POST['username'];
$day = mt_rand(1, 28); 
$month = mt_rand(1, 12); 
$year = mt_rand(1940, 1999); 
$ch = curl_init(); 
$password = randomPassword(); 

curl_setopt($ch, CURLOPT_URL,""); 
curl_setopt($ch, CURLOPT_POST, 1); 
curl_setopt($ch, CURLOPT_POSTFIELDS, 

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); 
$server_output = curl_exec ($ch); 
$result = json_decode($server_output); 

curl_close ($ch); 

// further processing .... 
if ($result->status == "1") 
    echo '<b>Account created !</b><br /><p>Username: '.$username.'<br />E-Mail: '.$mail.'<br />Password: '.$password.'<br /></p>'; 
    echo 'I don\'t know, error or whatever...'; 
<form method="post">
    <input type="text" name="username">
    <input type="submit" name="submit" value="Submit Username" >


New Member
Are there any benefits of using this account creator script other than for an easier process to register an Spotify account?

I do not see the point unless you have something planned for multiple Spotify accounts.
Last edited by a moderator:


Just a dude
vpsBoard Founder
Hey, sometimes a random project like this is good for retaining and learning new stuff.

I don't use Spotify, though thanks for sharing anyhow.


Active Member
Verified Provider
Pretty cool, can't see the use for it though, but cool non the less :D

PS: I prefer Deezer for my cloud music.


New Member
You can use it to create tons and tons of spotify accounts that you can't delete yourself, to protest their ridiculously cumbersome process of deleting them.

There is no way to delete a spotify account short of emailing the company and getting somebody to personally do it for you from the other end... even facebook isn't that bad.

I just went through this and googled "spotify account creator" to see if any body had had this idea as well... and it looks like you're more than halfway there...


100% Tier-1 Gogent
I use Spotify to get stains out in my laundry.

Let us not discourage anyone from coding, ever.  Hurrah!  Keep on friend, whatever this Spotify is for.