WEBSERVICE Function in Excel: Read Data From a URL

⏱ 1 min readUpdated 28 September 2026

LookupLevel: ExpertAvailable in: Excel 2013+

In this article
  1. Syntax
  2. Examples
  3. Example 1
  4. Common errors and fixes
  5. Related functions

WEBSERVICE downloads text from a web address (Windows desktop only). Combined with FILTERXML or TEXTAFTER it can read simple APIs.

Syntax

=WEBSERVICE(url)
Argument What it means
url Up to 2,048 characters, http or https.

Examples

Example 1

=WEBSERVICE("https://api.example.com/rate?from=USD&to=INR")

Returns the raw response text.

Common errors and fixes

You see Why, and the fix
#VALUE! The response is longer than 32,767 characters, or the URL is invalid.

FILTERXML · ENCODEURL

📚 Part of the free Excel course: Beginner → Expert · Try it in the Formula Lab or ask the AI Helper.

✨ Ask AI about this article

Stuck on a step? Ask a question and the AI answers using this article.

Free · AI can be wrong