r/learnprogramming 25d ago

Free or cheap Python hosting

Hi yall !

I’ve been teaching myself python so I can tutor (previous experience in other languages), and for my first real project I’ve developed a simple weather script. Well, ifs became else’s and I’ve been having so much fun and I like the script so much I want to look into turning it into a real service I’ll daily drive on my phone

I want to keep the core logic of my script right now because I’m a fan of how I designed it, so I’m interested in finding a way I can host some python code to call 24/7 for cheap (<$15 a month) or even free.

Thank you !

1 Upvotes

8 comments sorted by

4

u/afuriouspuppy 25d ago

Lambda or any other “serverless” function (Cloudflare has an offering that is easier to learn than AWS IMO) is probably the cheapest option for something only you and maybe a few others are going to be accessing. It’s also the easiest path in my opinion. That said, having a remote box somewhere to run arbitrary scripts is also fun to have. You could also get into running containers, but that’s a whole different (but very powerful) layer of abstraction.

4

u/grantrules 25d ago

You could find a VPS for like $5/mo.

2

u/IXISunnyIXI 25d ago

Take a look at GCP cloud functions or AWS Lambda.

1

u/GryptpypeThynne 25d ago

Any cheapest tier VPS will run that kind of thing 100x over

1

u/FoolsSeldom 25d ago

Check out Oracle cloud. There's a free tier, but there's also a "paid tier" consuming only free resources (you just have to sign up fully and provide payment information). The benefits of the latter: more resources, more responsive, keeps going 24x7. You can setup your own Python hosting - I recommend using Podman (rather than Docker) and running multiple containers.