---
title: Window.document
slug: Web/API/Window/document
tags:
  - API
  - HTML DOM
  - Property
  - Reference
  - Window
browser-compat: api.Window.document
---
{{APIRef}}

**`window.document`** returns a reference to the [document](/en-US/docs/Web/API/Document) contained in the window.

## Example

```js
console.log(window.document.title);
```

## Specifications

{{Specifications}}

## Browser compatibility

{{Compat}}
