CURUP, Indonesia — Hiding in the dense Sumatran jungle, the poacher chose a thin branch, coated it with homemade glue and played a snippet of birdsong on an old cellphone. Within moments, three tiny birds alighted on the branch and were trapped.

Known as ashy tailorbirds, they were destined for the Indonesian island of Java, where they were likely to spend their lives in a collector’s cage.

Millions of similar birds are stolen from the wild every year, and prized specimens can ultimately sell for thousands of dollars. These birds are not treasured for their plumage or meat, but for their songs.

An illicit trade that begins in the primeval forests takes many of the birds to Indonesia’s teeming capital, Jakarta, where they are entered into high-stakes singing competitions at which government officials frequently preside.