--- title: "hx-boost" description: "Converts links and forms to AJAX" --- The `hx-boost` attribute allows you to "boost" normal anchors and form tags to use AJAX instead. This has the [nice fallback](https://en.wikipedia.org/wiki/Progressive_enhancement) that, if the user does not have javascript enabled, the site will continue to work. ## Syntax For anchor tags, clicking on the anchor will issue a `GET` request to the url specified in the `href` and will push the url so that a history entry is created. The target is the `
` tag, and the `outerSync` swap strategy is used by default. All of these can be modified by using the appropriate attributes, except the `click` trigger. For forms the request will be converted into a `GET` or `POST`, based on the method in the `method` attribute and will be triggered by a `submit`. Again, the target will be the `body` of the page, and the `outerSync` swap will be used. The url will _not_ be pushed, however, and no history entry will be created. (You can use the [`hx-push-url`](/reference/attributes/hx-push-url) attribute if you want the url to be pushed.) ```html ``` These links will issue an ajax `GET` request to the respective URLs and swap the full response into the `` using `outerSync` — which replaces the body's children and syncs any attributes on the `` element itself (e.g. `class`, `data-*`) without removing and re-creating the node. ```html ``` This form will issue an ajax `POST` to the given URL and swap the full response into the ``. ## Advanced Syntax You can configure boost behavior using a config string that sets swap, target, and other options directly on the `hx-boost` attribute. Use `hx-boost:inherited` to pass that config down to all boosted descendants. ```html