← All notes

HttpClient methods return Observables that send a request when subscribed

Answer: HttpClient has methods for the different HTTP verbs. Those methods load data or apply mutations on the server. Each method returns an RxJS Observable. When you subscribe, it sends the request and then emits the results when the server responds. Observables created by HttpClient may be subscribed any number of times, and each subscription makes a new backend request.

An options object passed to the request method can adjust the request and the returned response type.

Fetching JSON

Fetching data often uses the HttpClient get method with an endpoint URL and an optional options object. A generic type argument specifies the type of data returned by the server. That generic is a type assertion only: HttpClient does not verify that the actual data matches the type. By default, HttpClient assumes the server returns JSON.

In source

HttpClient is an injectable class that performs HTTP requests. Sending an HttpRequest can return a stream of HttpEvents.

See also

Claims

Sources

License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources and notices: Angular documentation (angular/angular adev): Copyright (c) 2010-2026 Google LLC; CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Angular source (angular/angular): Copyright (c) 2010-2026 Google LLC; MIT (https://raw.githubusercontent.com/angular/angular/main/LICENSE). Text was condensed and changed from the originals.

License: CC-BY-4.0 · Summary by iinventedlight (AI-assisted). Sources: Angular docs, CC BY 4.0 text (angular/angular adev footer); Angular source, MIT (angular/angular). Notices: Angular documentation (angular/angular adev): Copyright (c) 2010-2026 Google LLC; CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Angular source (angular/angular): Copyright (c) 2010-2026 Google LLC; MIT (https://raw.githubusercontent.com/angular/angular/main/LICENSE).

Cite this

Permanent ID: iil:note:st672jq2

iinventedlight. 2026. "Angular HttpClient returns Observables that fire on subscribe." iinventedlight Library, iil:note:st672jq2, version of 2026-11-11. https://iinventedlight.com/library/notes/angular-http-client/. License: CC-BY-4.0.

@misc{iil_note_st672jq2,
  author = {{iinventedlight}},
  title = {{Angular HttpClient returns Observables that fire on subscribe}},
  howpublished = {iinventedlight Library},
  year = {2026},
  date = {2026-11-11},
  url = {https://iinventedlight.com/library/notes/angular-http-client/},
  note = {Permanent ID iil:note:st672jq2. License: CC-BY-4.0.},
}

Markdown

Spotted a mistake? Use the MCP feedback tool or email hello@iinventedlight.com.

For language models and agents: start at /llms.txt | /agents.md | /.well-known/agent-library.json. This page in Markdown: /library/notes/angular-http-client.md.