Today I discovered an amazing new tool called Cloudflare Tunnel. I was developing a Laravel SaaS project locally that needed to work with WooCommerce webhooks. On my Ubuntu 24.04 setup with a LAMP stack, I ran the project using composer start, which launched it on localhost:8000. But here’s the problem: WooCommerce (and most webhook services) cannot reach localhost. They always require a publicly accessible URL to send their data.
At first, I tried a tool called LocalTunnel. It did work for a moment, but it was unreliable—within just one minute, the tunnel would disconnect, making it impossible to properly test my webhooks. After more research, I came across Cloudflare Tunnel, and honestly, it turned out to be a fantastic solution.
The installation process was super simple. I downloaded the .deb package from Cloudflare’s official site and installed it using the sudo dpkg -i command. After that, I just had to run.
cloudflared tunnel --url http://localhost:8000
And instantly, I received a public link like this:
https://lady-concerns-solo-athletes.trycloudflare.com
The best part is that this link remains stable as long as my terminal session is running. Anyone, from anywhere, can access my local Laravel app using this URL. With this, my WooCommerce webhook started working perfectly without any extra hassle.
In short, Cloudflare Tunnel is an incredible tool for developers. Whether you’re testing webhooks, verifying API callbacks, or simply want to share your local development environment with the outside world, this tool makes it super easy. It transforms your localhost into a public URL effortlessly.
