Hacker News (AI keywords)Jun 16, 2026, 4:40 PMmrshu

TIL: Make HTTP Requests Without curl Using Bash /dev/TCP

Original: TIL: You can make HTTP requests without curl using Bash /dev/TCP

Bash's built-in /dev/tcp pseudo-device lets you issue raw HTTP requests with no external tools.

A developer shares a lesser-known Bash capability: the /dev/tcp virtual filesystem, which opens raw TCP connections using only shell built-ins. By writing HTTP headers to a file descriptor and reading the response back, you can fetch web resources without curl, wget, or any installed HTTP client. This technique is especially valuable in minimal containers, restricted shells, or embedded environments where external binaries may not exist.

Most developers reach for curl or wget the moment they need to make an HTTP request from a shell script. A TIL (Today I Learned) post by Marek Suppa highlights a surprisingly capable alternative that ships with Bash itself: the /dev/tcp pseudo-device.

Full summary

Free shows the 3-line summary; Pro unlocks the full deep summary (~300 words) so you never have to click through.

See Pro plans →

Want the original English / full article?

Read on Hacker News (AI keywords) →

Summaries are AI-generated; the original article is authoritative.