United States
The everyday instrument is the Stored Communications Act, 18 U.S.C. § 2703, which grades access by intrusiveness. A prosecutor's subpoena, with no judge involved, obtains the subscriber's name, address, session times, IP addresses and means of payment (§ 2703(c)(2)). A court order under § 2703(d), issued on specific and articulable facts, reaches other non-content records, and a warrant reaches content. Before any of that, § 2703(f) lets the government tell a provider by letter to preserve everything for 90 days, renewable for another 90. Section 2705(b) lets a court forbid the provider from telling you, and national security letters under § 2709 let the FBI obtain subscriber and billing records with no court at all and a non-disclosure obligation built in.
The CLOUD Act, enacted on 23 March 2018, added § 2713: a US provider must produce data in its possession, custody or control whether it is stored inside or outside the United States. The one safety valve, a motion to quash under § 2703(h), is available only when the customer is not a US person, does not live in the US, and disclosure would put the provider at odds with the law of a "qualifying foreign government", meaning a country that has signed an executive agreement. As of 31 October 2026 the Justice Department lists two: the United Kingdom and Australia. A Panamanian, Swiss or Brazilian customer of a US host does not get that motion.
Foreign intelligence runs on a separate track. Section 702 of FISA (50 U.S.C. § 1881a) authorises targeting non-US persons reasonably believed to be outside the United States through directives served on "electronic communication service providers", under programmes the FISA Court approves once a year without reviewing individual targets. The April 2024 reauthorisation (RISAA) widened that definition to any other service provider with access to equipment used to transmit or store communications (§ 1881(b)(4)(E)), wording broad enough to reach a data-centre operator. The statute lapsed at midnight on 12 June 2026, its first lapse since 2008, but the certifications approved on 17 March 2026 stay in force until 17 March 2027 and directives already served remain binding. If you are not a US person and you rent a server in Virginia, you belong to exactly the population 702 was written for.
Copyright has its own machinery. A DMCA notice is not a court order even in the United States; what makes US hosts remove content within hours is the safe harbour of 17 U.S.C. § 512(c), which they lose if they sit on a notice. Section 512(h) lets a rights holder obtain, from the clerk of any district court, a subpoena identifying the customer, and no judge examines its merits.