HTML noresize Attribute
The obsolete HTML noresize attribute was historically used on the <frame> element to prevent users from resizing frames by dragging the border between them.
noresize attribute belongs to the obsolete <frame> and <frameset> layout system and should not be used in modern HTML. Use ordinary HTML with CSS layout techniques or an <iframe> when another document needs to be embedded.
Historical Syntax
The noresize attribute was a Boolean attribute placed on a <frame> element:
<frameset cols="30%,70%">
<frame src="navigation.html" noresize>
<frame src="content.html">
</frameset>
When supported, noresize prevented the user from dragging the border next to that frame to change the frame dimensions.
Historical Elements
The noresize attribute was associated with the obsolete <frame> element used in frameset documents.
| Element | Historical Purpose |
|---|---|
<frame> |
Prevented users from resizing the frame by dragging an adjacent frame border. |
Historical Use
Older frameset layouts divided the browser window into separate regions, with each <frame> displaying a different HTML document. Depending on the layout, users could drag the border between frames to change the amount of space assigned to each region.
Adding noresize to a frame prevented resizing along the border associated with that frame.
<frameset cols="200,*">
<frame src="menu.html" noresize>
<frame src="main.html">
</frameset>
In this example, the first frame was intended to remain at its assigned width instead of allowing the user to change the layout by dragging the divider.
Why It Became Obsolete
The noresize attribute became obsolete along with the frameset layout system it was designed to control. Modern webpages no longer use <frameset> and <frame> to divide the browser window into separate documents.
Modern layouts keep the page structure in a normal HTML document and use CSS to arrange sections into rows, columns, sidebars, and other layouts. This provides much greater control over responsive design and accessibility.
Modern Alternative
There is no direct modern replacement for the noresize attribute because modern HTML does not use frameset borders as draggable page dividers. Replace the old frameset structure with ordinary HTML and CSS.
Historical HTML
<frameset cols="200,*">
<frame src="menu.html" noresize>
<frame src="main.html">
</frameset>
Modern HTML
<div class="page-layout">
<nav>
Navigation
</nav>
<main>
Main Content
</main>
</div>
Modern CSS
.page-layout {
display: grid;
grid-template-columns: 200px 1fr;
}
nav {
padding: 20px;
}
main {
padding: 20px;
}
CSS Grid can create a fixed-width navigation column and a flexible content column without using frames. There is no draggable frame border, so an equivalent to noresize is unnecessary.
Learn More About Modern Layouts
The CSS layout tutorials explain how to create page structures without obsolete frames:
- CSS Grid - Create layouts using rows and columns.
- CSS Flexbox - Arrange and size elements along a row or column.
Legacy Browser Support
The noresize attribute was supported by browsers that implemented traditional frameset layouts. Its purpose was specifically tied to resizing borders between <frame> elements.
The <frame> and <frameset> elements are obsolete and must not be used in modern HTML. New webpages should use ordinary HTML and CSS for page layouts.
For additional information about historical browser compatibility, visit Can I Use? . Search for the HTML element or attribute you want to check. Search results can include related HTML features, element attributes, APIs, and other technologies, so select the result that most closely matches the legacy feature you are researching.
Related Attributes
Other obsolete attributes associated with traditional frame layouts include:
frameborder- Historically controlled whether a frame border was displayed.framespacing- Historically controlled spacing between frames.marginheight- Historically controlled vertical spacing inside a frame.marginwidth- Historically controlled horizontal spacing inside a frame.scrolling- Historically controlled scrollbar behavior in frames.
Specifications
The noresize attribute belongs to the obsolete <frame> element and should not be used in modern HTML. The HTML Living Standard retains legacy processing information for old frame documents, including the historical behavior of noresize, while identifying <frame> and <frameset> as entirely obsolete. See the WHATWG HTML Living Standard for information about obsolete features.
