> ## Documentation Index
> Fetch the complete documentation index at: https://docs.comfy.org/llms.txt
> Use this file to discover all available pages before exploring further.

# VAEEncodeAudio - ComfyUI Built-in Node Documentation

> Complete documentation for the VAEEncodeAudio node in ComfyUI. Learn its inputs, outputs, parameters and usage.

> This documentation was AI-generated. If you find any errors or have suggestions for improvement, please feel free to contribute! [Edit on GitHub](https://github.com/Comfy-Org/embedded-docs/blob/main/comfyui_embedded_docs/docs/VAEEncodeAudio/en.md)

The VAEEncodeAudio node converts audio data into a latent representation using a Variational Autoencoder (VAE). It takes audio input and processes it through the VAE to generate compressed latent samples that can be used for further audio generation or manipulation tasks. The node automatically resamples audio to match the VAE's expected sample rate if needed before encoding.

## Inputs

| Parameter | Data Type | Required | Range | Description                                                                  |
| --------- | --------- | -------- | ----- | ---------------------------------------------------------------------------- |
| `audio`   | AUDIO     | Yes      | -     | The audio data to encode, containing waveform and sample rate information    |
| `vae`     | VAE       | Yes      | -     | The Variational Autoencoder model used to encode the audio into latent space |

**Note:** The audio input is automatically resampled to match the VAE's expected sample rate (default: 44100 Hz) if the original sample rate differs from this value. If the input audio is None (e.g., the source video has no audio track), the node will raise an error.

## Outputs

| Output Name | Data Type | Description                                                                     |
| ----------- | --------- | ------------------------------------------------------------------------------- |
| `LATENT`    | LATENT    | The encoded audio representation in latent space, containing compressed samples |

***

**Source fingerprint (SHA-256):** `5c65a853a121a557a5342d337c27e2ea3acff48e6b911bdaf27c89d4c7dc01b6`
