Personal recipe here and others with more experience can weigh in.
I start with an organic garden soil with no nutrients added. I bought mine at a big box store, $5 a bag. I then screen it to remove all the big chunks of wood/bark which I compost or use as mulch.
Then I add perlite about 20%. Big bag cost me about $20 at big box store and worm casings.
Next is whatever I have been saving from the house. Ground eggshells, dried ground banana peels, dried coffee grounds (most local coffee shops give away grounds), my friend’s soil primer made from pine (discontinued), all my trimmed fan leaves dried and ground and finally all the soil from previous grows/failed clones. I add in ironite and Dr. Earth tomato food. I also bury a real copper penny in every grow bag because my 100% Irish granny did this with every houseplant.
Will it have everything cannabis needs? Probably not.
This is just me and what seems to be working now. I continue to learn and experiment.
Best to you my friend.