Youtube video ids are just 64 bit numbers that have been base64 encoded with a slightly modified character set. Here is an example of a Python script that converts the Youtube id back to a 64 bit int representation:
Conversation
Replying to
import base64
import struct
yt_id = '_ZPpU7774DQ' + '=' # Add padding
yt_id = yt_id.replace('-','+').replace('_','/')
yt_id = struct.unpack('L', base64.b64decode(yt_id))[0]
print(yt_id)
2
7
This will allow you to store Youtube ids with just 4 bytes instead of 11 (which comes in handy when you are storing billions of them).
1
8
