Currently, I am using Cloudinary but the management interface leaves a lot to be desired. I have seen some static sites use GitHub repositories for hosting images which I think is a pretty cool hack.
Ask HN: Where do you host images for your blog or landing pages?
1–10 of 66 posts
I am curious what are the current best practices and offerings for hosting images (or short videos, gifs, etc.) for small to mid scale websites?
Re: Ask HN: Where do you host images for your blog or landing pages?
#2When it comes to GitHub repo, what does the URL of the image look like? Is some kind of hash added to the filename? At the moment I use media files from my WordPress blog to store images.
Re: Ask HN: Where do you host images for your blog or landing pages?
#3[deleted]
Re: Ask HN: Where do you host images for your blog or landing pages?
#4I guess I'm behind the times, but I just store them on the file system where I am serving the website from.
Re: Ask HN: Where do you host images for your blog or landing pages?
#5In the same place. Why anything else? Much simpler, and no extra HTTPS connection to make, and probably within ε on file delivery performance (though that’s heavily subjective). There’s almost never any reason to do it any other way.
Re: Ask HN: Where do you host images for your blog or landing pages?
#6When it comes to GitHub repo, what does the URL of the image look like? Is some kind of hash added to the filename? At the moment I use media files from my WordPress blog to store images.
I just add them to an img folder in my Github repository and it is then served as part of the Github page. Just using `src=img/picture.jpg` works fine.
Re: Ask HN: Where do you host images for your blog or landing pages?
#7I have an entire repo set up to share images via iPic - I just select an image locally and with a keyboard command updload it and add the url to my clipboard
Re: Ask HN: Where do you host images for your blog or landing pages?
#8The image is placed in my website directory and then my static site generator, jekyll, uses a relative path tag to generate the path for the final compiled website on my machine. This static website is then uploaded to github. If I was uploading elsewhere, the workflow would be the same. Only the relative path is hardcoded and the domain therefore doesn’t matter. The true filepath is to some github link in my “_site” directory, but neither I nor the user see it. Static sites are very easy to manage in this way.
Re: Ask HN: Where do you host images for your blog or landing pages?
#9I commit to a github repo and that gets deployed to cloudflare pages. https://pages.cloudflare.com/
I use Zola the static site generator. My repo is here https://github.com/purton-tech/cloak/tree/main/www
Re: Ask HN: Where do you host images for your blog or landing pages?
#10Just curious, what do you use for hosting the blog or landing page itself?
For example, we use GitHub Pages for hosting the landing page. So for hosting images, we use GitHub itself and it mostly works.
For the blog, we currently use Substack, but thinking of maybe moving it to GitHub Pages too.
FYI, here is our repo: https://github.com/dstackai/dstack