---
title: "Nuxt Config · Nuxt Scripts"
meta:
  description: "Nuxt Scripts lets you load third-party scripts with better performance, privacy, security and DX. It includes many popular third-parties out of the box."
  "og:description": "Nuxt Scripts lets you load third-party scripts with better performance, privacy, security and DX. It includes many popular third-parties out of the box."
  "og:title": "Nuxt Config · Nuxt Scripts"
---

```

Nuxt Scripts on GitHub

**

**Api**

# **Nuxt Config**

[Copy for LLMs](https://scripts.nuxt.com/docs/v0/api/nuxt-config.md)

## `registry`

- Type: `ScriptRegistry`

Global registry scripts that should be loaded.

See the [**~~Script Registry~~**](https://scripts.nuxt.com/scripts) for more details.

## `defaultScriptOptions`

- Type: `NuxtUseScriptOptions`- Default: `{ trigger: 'onNuxtReady' }`

Default options for scripts. See the [**~~useScript~~**](https://scripts.nuxt.com/docs/api/use-script) documentation for more details.

## `globals`

- Type: `(NuxtUseScriptInput | [NuxtUseScriptInput, NuxtUseScriptOptions])[]`- Default: `[]`

Global scripts that should be loaded on all pages. This is a configuration for the [**~~useScript~~**](https://scripts.nuxt.com/docs/api/use-script) composable.

See the [**~~Globals~~**](https://scripts.nuxt.com/docs/guides/global) documentation for more details.

## `enabled`

- Type: `boolean`- Default: `true`

Disables the Nuxt Scripts module.

## `debug`

- Type: `boolean`- Default: `false`

Enable to see debug logs.

## `assets`

- Type: `object`- Default: `{ prefix: '/_scripts/', strategy: 'public' }`

Controls the way scripts are bundled to be served by Nuxt.

See the [**~~Bundling~~**](https://scripts.nuxt.com/docs/guides/bundling) documentation for more details.

## `assets.fallbackOnSrcOnBundleFail`

- Type: `boolean`- Default: `false`

Fallback to the remote src URL when `bundle` fails when enabled. By default, the bundling process stops if the third-party script can't be downloaded.

## `assets.fetchOptions`

- Type: `object`- Default: `{ retry: 3, retryDelay: 2000, timeout: 15_000 }`

Options to pass to the fetch function when downloading scripts.

[~~Edit this page~~](https://github.com/nuxt/scripts/edit/0.x/docs/content/docs/v0/3.api/5.nuxt-config.md)

[~~Markdown For LLMs~~](https://scripts.nuxt.com/docs/v0/api/nuxt-config.md)

[**useScriptEventPage** API documentation for the useScriptEventPage function.](https://scripts.nuxt.com/docs/v0/api/use-script-event-page) [**Nuxt App Hooks** Use Nuxt App hooks to extend the Nuxt Scripts runtime behavior.](https://scripts.nuxt.com/docs/v0/api/nuxt-app-hooks)

**On this page **

- [registry](#registry) - [defaultScriptOptions](#defaultscriptoptions) - [globals](#globals) - [enabled](#enabled) - [debug](#debug) - [assets](#assets) - [assets.fallbackOnSrcOnBundleFail](#assetsfallbackonsrconbundlefail) - [assets.fetchOptions](#assetsfetchoptions)