DOM & HTML
Range API
Represent a fragment of a document that can contain nodes and parts of text nodes.
Checking support...
Feature Not SupportedThis browser does not support the Range API Web API feature. Try testing in a modern browser (such as Chrome, Edge, Safari, or Firefox).
Advertisement
Interactive Input Workspace
Ready for input
Web API Execution Output
Result output will be displayed here after processing...
Native JavaScript Code Example (Zero Libraries)
const range = document.createRange(); range.selectNodeContents(document.body); const text = range.toString();
About the Range API Web API
The Range interface represents a fragment of a document that can contain nodes and parts of text nodes.
Specification:W3C & WHATWG Web API Standard
Sponsored Content