← BACK TO BLOG
March 21, 2026
ModWorks Team

How to Optimize YTD Textures for FiveM: Fix Streaming and Reduce File Size

guidefivemtexturesperformance

Why YTD Optimization Matters for FiveM

FiveM enforces a 16MB physical memory limit per texture dictionary (YTD file). When a YTD exceeds this limit, the game's streaming system can't load it properly. The result is what FiveM server owners call the "city bug" — buildings, roads, and objects fail to stream in, leaving players staring at a flat, untextured void.

This isn't a bug in FiveM. It's how GTA V's streaming system works. The game loads and unloads assets constantly as players move through the world. Textures that are too large block the streaming pipeline, preventing other assets from loading.

Even if your YTD files are under 16MB, oversized textures still cause problems. They consume more VRAM, increase client download times, and can cause frame drops when the game loads them. Optimizing your textures improves performance for every player on your server.

Understanding YTD Files

A YTD (Yep Texture Dictionary) file is a container that holds one or more textures. Each texture inside has a name, dimensions (width and height), a pixel format (like DXT1, DXT5, or BC7), and one or more mipmap levels.

Key concepts:

Dimensions — Texture width and height in pixels. GTA V requires power-of-two dimensions: 64, 128, 256, 512, 1024, 2048, or 4096. Non-power-of-two textures cause rendering errors.

Pixel format — How color data is stored. DXT1 (also called BC1) uses 4 bits per pixel and doesn't support transparency. DXT5 (BC3) uses 8 bits per pixel and supports full alpha transparency. BC7 offers the best quality at 8 bits per pixel but isn't supported by all hardware. For most vehicle and ped textures, DXT5 is the standard.

Mipmaps — Smaller pre-generated versions of the texture used when the object is viewed from a distance. A 1024x1024 texture with full mipmaps includes versions at 512x512, 256x256, and so on down to 1x1. Mipmaps add about 33% to the texture size but significantly improve rendering performance and visual quality at distance.

Physical memory — The size of the highest-resolution mipmap level. This is what FiveM's 16MB limit applies to. The total file size on disk includes all mipmap levels, but the physical memory cost is what matters for streaming.

How to Check Your YTD File Sizes

Before optimizing, you need to know which files are problematic. Open your YTD files in ModWorks to see:

  • Total file size on disk
  • Number of textures inside
  • Each texture's dimensions, format, and mipmap count
  • Estimated physical memory usage

Any YTD with physical memory usage approaching or exceeding 16MB needs attention.

Optimization Strategies

1. Reduce Texture Dimensions

The single most effective optimization. A 4096x4096 DXT5 texture uses 16MB of physical memory by itself — that's the entire FiveM limit in one texture. Reducing it to 2048x2048 drops it to 4MB, a 75% reduction.

For most GTA V assets, these dimensions work well:

Asset TypeRecommended Max Size
Vehicle body2048x2048
Vehicle interior1024x1024
Vehicle extras/details512x512
Ped body1024x1024
Ped face1024x1024
Prop/small object512x512
Signs/decals256x256 or 512x512

Players won't notice the difference between 4096 and 2048 on most vehicles during normal gameplay. The texture is mapped across a 3D surface and viewed from varying distances — the raw pixel count matters far less than you'd think.

2. Use the Right Pixel Format

Using DXT5 for a texture that has no transparency wastes space. Switch opaque textures to DXT1, which uses half the memory.

  • DXT1 (BC1) — Use for opaque textures with no transparency: body paint, tires, most interior surfaces
  • DXT5 (BC3) — Use for textures that need transparency: windows, decals, livery overlays, lights
  • BC7 — Use sparingly for high-quality textures where banding is visible in DXT formats. Higher quality but not universally supported on older GPUs

3. Remove Unnecessary Textures

Many vehicle mods include textures that aren't used — leftover livery slots, duplicate textures with slightly different names, or debug textures left from development. Open the YTD and check if every texture is actually referenced by the model. Remove any that aren't.

4. Consolidate Texture Dictionaries

Some mod authors split textures across multiple YTD files when they could fit in one, or put everything in one massive YTD when it should be split. The goal is to keep each YTD well under 16MB physical memory while grouping textures that are loaded together.

For vehicles, a common setup:

  • vehiclename.ytd — Main vehicle textures (body, wheels, interior)
  • vehiclename+hi.ytd — High-detail textures loaded at close range

5. Generate Proper Mipmaps

Some mod textures ship without mipmaps or with incomplete mipmap chains. Missing mipmaps force the game to use the full-resolution texture at all distances, wasting VRAM and hurting performance.

Always ensure textures have a full mipmap chain generated. ModWorks generates mipmaps automatically when processing YTD files.

Batch Optimization With ModWorks

For servers with dozens or hundreds of vehicle and ped resources, manually optimizing each YTD isn't practical. ModWorks includes a YTD optimizer that processes files in bulk:

  1. Select one or more YTD files or point it at an entire resource folder
  2. Set your target dimensions and format preferences
  3. The optimizer resizes oversized textures, converts formats where appropriate, and regenerates mipmaps
  4. Review the before/after size comparison and apply the changes

This can reduce a server's total asset size dramatically — it's common to see 50-70% reductions on servers using unoptimized community vehicle packs.

Measuring the Impact

After optimizing, verify the improvement:

File size — Compare the total size of your resources folder before and after. Smaller files mean faster client downloads.

Physical memory — Open optimized YTDs in ModWorks and check that physical memory per file is well under 16MB.

In-game testing — Drive around the areas where your custom assets load. If you previously saw the city bug or texture pop-in, it should be resolved. Use FiveM's built-in resmon command to monitor streaming memory usage.

Common Mistakes

Resizing to non-power-of-two dimensions. A 1920x1080 texture will cause rendering problems. Always use power-of-two values (256, 512, 1024, 2048, 4096).

Removing mipmaps to reduce file size. This is counterproductive — the file gets slightly smaller on disk, but rendering performance gets worse and the physical memory usage stays the same.

Over-compressing textures. Reducing a 2048x2048 texture to 128x128 saves space but looks terrible in-game. Find the balance where quality loss isn't visible during normal gameplay.

Optimizing only one resource. If your server has 200 vehicle resources and you optimize 10, the improvement will be minimal. Batch-process everything for meaningful results.

Further Reading