---
hide_title: false
hide_table_of_contents: false
pagination_next: null
pagination_prev: null
---
# Headers.get()

The **`get()`** method of the [`Headers`](../../../globals/Headers/Headers.mdx) interface
returns a byte string of all the values of a header within a `Headers` object
with a given name. If the requested header doesn't exist in the `Headers`
object, it returns `null`.

## Syntax

```js
get(name)
```

### Parameters

- `name`
  - : The name of the HTTP header whose values you want to retrieve from the
    `Headers` object. If the given name is not the name of an HTTP header, this
    method throws a `TypeError`. The name is case-insensitive.

### Return value

A [`String`](../../../globals/String/String.mdx) sequence representing the values of the retrieved header or
`null` if this header is not set.
