Sitemap
Ihunanyachi Thompson

Ihunanyachi Thompson

Ihunanyachi Thompson is an entrepreneur, a WordPress Design Engineer with over 6yrs of experience building web solutions and the co-founder of UsefulPDF.

I Vibe Coded an Image Converter With ChatGPT in 20 Minutes — Here’s What I Learned

3 min readNov 26, 2025

--

Press enter or click to view image in full size

Unless you’ve been living under a rock, you know what vibe coding is.

Oh, you’ve been living under a rock? Fine.

Vibe coding is basically you telling AI what you want, and it writes the code for you while you sit there sipping your coffee (or vodka, your choice, I won’t judge).

I want to share how I built a fully working image converter in just 20 minutes using ChatGPT. Trust me, I’m still surprised it worked.

Let’s dive in.

The Problem

So I had a folder full of images. JPGs, PNGs, and those stubborn HEIC files from my iPhone that nobody seems to want to open. I needed them all in WebP format because, well, WebP is lighter, faster, and better for the web.

Now I could have downloaded some random app or paid for some tool online. But where’s the fun in that? I said to myself, “Let me try this vibe coding thing everyone is talking about.”

The Vibe Coding Session

I opened ChatGPT and just started explaining my problem like I was talking to a friend. No fancy technical jargon. Just vibes.

I said something like: “I want to convert all my images to WebP. JPG, PNG, HEIC, and everything else. Put the output in one clean folder. Don’t touch my originals.”

And ChatGPT understood. I mean, it really understood.

Within a few back-and-forth messages, I had a working Python script. Did I write most of the code myself? No. Did I understand what was happening? Mostly. Did it work? Absolutely yes!

What The Tool Does

The script converts:

  • JPG
  • PNG
  • WEBP (re-compresses it)
  • HEIC (yes, iPhone photos!)

And saves everything into a clean webp_output folder inside your chosen directory.

✔️ It does NOT touch your original images
✔️ It creates exactly ONE output folder
✔️ It prints a nice log so you know what’s happening

Get Ihunanyachi Thompson’s stories in your inbox

Join Medium for free to get updates from this writer.

Example output:

🔄 Converting images inside: /Users/admin/.../New-collection
📁 Output folder: /Users/admin/.../New-collection/webp_output
✅ Converted: IMG_3358.HEIC → IMG_3358.webp

Beautiful, right?

The Challenges (and How We Fixed Them)

Now I won’t lie to you. It wasn’t all smooth. Some wise people usually say it’s good to learn from one’s mistakes, but it’s better to learn from others' mistakes. So let me save you the stress.

❌ HEIC files were failing
The script couldn’t read iPhone photos at first. ChatGPT suggested installing pillow-heif and adding one line of code. Problem solved.

❌ Output folder creating itself inside itself
This was funny and annoying at the same time. We fixed it by using absolute paths. Now it creates exactly one folder. No drama.

❌ “python: command not found”
MacOS users, use python3 instead of python. You're welcome.

How To Use It Yourself

  1. Create a virtual environment:
python3 -m venv venv
source venv/bin/activate
  1. Install the requirements:
pip install pillow pillow-heif
  1. Run the script:
python convert_webp.py /path/to/your/image-folder

That’s it. Your images will be waiting for you in the webp_output folder.

Want the full code? Grab it here: GitHub Repository

What I Learned

If I haven’t learnt anything at all, I would say I have learnt that you don’t need to be a coding expert to build useful tools anymore. AI has changed the game. You just need to know what you want and how to explain it clearly.

Vibe coding is not lazy coding. It’s smart coding. You’re still thinking, still problem-solving, still learning. You just have a very fast assistant doing the typing.

Final Thoughts

20 minutes. That’s all it took. From idea to working tool. No tutorial hunting. No Stack Overflow rabbit holes. Just me, ChatGPT, and good vibes.

I will be documenting more of these vibe coding sessions. What I build, what I learn — all of it. So you too can experience my journey as I make progress in building more useful things.

Thank you ChatGPT for a lesson well coded. 😁

Have you tried vibe coding yet? Drop a comment and let me know what you’ve built!

I placed the GitHub link right after the usage instructions, that’s where readers who want to try it themselves will naturally look for it. Clean and accessible.

--

--

Ihunanyachi Thompson

Written by Ihunanyachi Thompson

Ihunanyachi Thompson is an entrepreneur, a WordPress Design Engineer with over 6yrs of experience building web solutions and the co-founder of UsefulPDF.