October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsWindows FixRecommendedWindows errors stealing your time? Find the fix fastScan stability, cleanup and performance issues.Fix NowOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk4 min

Angular NG0913: How to Fix Runtime Image Performance Warnings

Angular NG0913 warns about oversized image downloads and lazy-loaded LCP images. Learn when to resize, use responsive images, or prioritize loading.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

NG0913 is an Angular runtime warning about image loading. It appears when an image download is substantially larger than its rendered size, or when the page’s Largest Contentful Paint (LCP) image is marked for lazy loading. Resize or serve responsive images to address the first case; prioritize the LCP image so it can load promptly in the second.

What does NG0913 mean?

NG0913 covers two image-loading conditions, not every kind of slow runtime behavior. Angular identifies the affected image by its URL in the console warning; use that URL to find the corresponding <img> element in your application. Angular’s NG0913 documentation describes both triggers.

As an Amazon Associate I earn from qualifying purchases.

An image is much larger than its rendered size

Angular compares the downloaded image’s intrinsic dimensions with its displayed dimensions after CSS sizing and adjustment for the device pixel ratio. It warns when the downloaded image is more than 1200 pixels too large in either dimension. The threshold is documented by Angular; the retrieved documentation does not state a publication year. An oversized download can slow page loading and negatively affect Core Web Vitals.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The LCP image is lazy-loaded

The LCP element is the largest contentful element rendered during page load. If Angular detects loading="lazy" on that element, it warns because the browser may need to perform layout calculations to determine whether the image is in the viewport before requesting it. That can delay the image that matters most to the initial visual load.

#1 Best Overall
Philips 24 Inch Computer Monitor FHD 100Hz VA VESA Flicker-Free, 241V8LB
  • CRISP CLARITY: This 23.8″ Philips V line monitor delivers crisp Full HD 1920x1080 visuals. Enjoy movies, shows and videos with remarkable detail
  • INCREDIBLE CONTRAST: The VA panel produces brighter whites and deeper blacks. You get true-to-life images and more gradients with 16.7 million colors
  • THE PERFECT VIEW: The 178/178 degree extra wide viewing angle prevents the shifting of colors when viewed from an offset angle, so you always get consistent colors
  • WORK SEAMLESSLY: This sleek monitor is virtually bezel-free on three sides, so the screen looks even bigger for the viewer. This minimalistic design also allows for seamless multi-monitor setups that enhance your workflow and boost productivity
  • A BETTER READING EXPERIENCE: For busy office workers, EasyRead mode provides a more paper-like experience for when viewing lengthy documents

How do I fix an oversized image warning?

Choose the remedy that fits how the image is used. A fixed, known-size slot may need only a smaller source file; layouts that vary by viewport or pixel density benefit from responsive candidates.

Remedy Best fit What to do
Use a smaller source image A fixed image slot with a suitable asset available Serve a source whose dimensions are closer to the rendered requirement.
Use srcset and sizes Images displayed at different sizes across layouts or pixel densities Provide multiple image candidates with srcset, and describe the rendered slot with sizes so the browser can choose an appropriate candidate.
Use NgOptimizedImage Angular applications that want built-in image optimization and responsive-image support Use the directive’s responsive-image features; an image loader is optional and can enable URL transformations through an image CDN.

Angular’s NG0913 guidance lists smaller sources, srcset, and NgOptimizedImage as remedies. Its image optimization guide recommends setting sizes for responsive images so the browser can select an appropriate candidate.

Rank #2
Philips 22 Inch Computer Monitor FHD 100Hz VA VESA Flicker-Free, 221V8LB
  • CRISP CLARITY: This 22 inch class (21.5″ viewable) Philips V line monitor delivers crisp Full HD 1920x1080 visuals. Enjoy movies, shows and videos with remarkable detail
  • 100HZ FAST REFRESH RATE: 100Hz brings your favorite movies and video games to life. Stream, binge, and play effortlessly
  • SMOOTH ACTION WITH ADAPTIVE-SYNC: Adaptive-Sync technology ensures fluid action sequences and rapid response time. Every frame will be rendered smoothly with crystal clarity and without stutter
  • INCREDIBLE CONTRAST: The VA panel produces brighter whites and deeper blacks. You get true-to-life images and more gradients with 16.7 million colors
  • THE PERFECT VIEW: The 178/178 degree extra wide viewing angle prevents the shifting of colors when viewed from an offset angle, so you always get consistent colors

How do I set up NgOptimizedImage?

Import NgOptimizedImage from @angular/common, include it in the component’s imports, and replace the image’s src binding with ngSrc. The directive requires width and height; for responsive images, these attributes should represent the image’s intrinsic dimensions. The dimensions also help prevent image-related layout shifts.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
import { NgOptimizedImage } from '@angular/common';

@Component({
  // ...
  imports: [NgOptimizedImage],
  template: `
    <img ngSrc="/assets/example.jpg" width="1200" height="800" alt="Example">
  `
})

The directive can generate a srcset and add preconnect or server-rendered preload hints. A loader is optional. Angular says the directive became stable in Angular v15 and was backported as stable to v13.4.0 and v14.3.0; check your project’s Angular version and current guide before making upgrade-specific decisions. See the official setup guide.

Rank #3
Sale
Dell 24 Monitor - SE2426H - 23.8-inch FHD (1920x1080) 144Hz 1ms Display, in-Plane Switching (IPS) Technology, AMD FreeSync™, TÜV 3-Star 2X HDMI, Tilt
  • Clear visuals. Fluid motion: A 144Hz refresh rate and 1ms MPRT deliver smooth, tear‑free motion across work, gaming, and streaming for clearer, more fluid viewing.
  • Eye comfort: TÜV Rheinland 3‑star* certification reduces harmful blue light while preserving stunning color quality without compromise. *TÜV Rheinland 3-star eye comfort certification.
  • Wide viewing angle: Get consistent views across a wide 178° /178° viewing angle.
  • In-Plane Switching (IPS): See excellent color accuracy and consistency across wide viewing angles with In-plane Switching (IPS) technology.
  • Ultra-thin bezels: Maximize your viewing experience with thin bezels.

Why is Angular warning that my LCP image is lazy-loaded?

Do not defer the image that is responsible for the page’s LCP. You can change its loading behavior to eager, or use NgOptimizedImage and mark it with priority. Angular documents that priority applies fetchpriority="high" and loading="eager", and generates a preload link when rendering on the server. The directive lazy-loads other images by default, so reserve priority for images that genuinely need it. Its API warns that making non-priority images eager or auto can hurt loading performance.

For an image using the directive, the relevant distinction is:

Rank #4
Sale
Samsung 27" Essential S3 (S36GD) Series FHD 1800R Curved Computer Monitor
  • CURVED FOR ENHANCED ENGAGEMENT: An immersive viewing experience with a curved monitor that wraps more closely around your field of vision; It creates a wider view, enhancing depth perception and minimizing peripheral distraction
  • SMOOTH PERFORMANCE FOR SEAMLESS CONTENT: Stay in the action when playing games, watching videos, or working on creative projects; The 100Hz refresh rate reduces lag and motion blur so you don't miss a thing in fast-paced moments¹
  • MORE GAMING POWER: Gain the edge with optimizable game settings; Color and image contrast can be adjusted to see scenes more vividly and spot enemies hiding in the dark; Game Mode adjusts any game to fill the screen so you can view every detail²
  • KEEP IT EASY ON THE EYES: Care for your eyes and stay comfortable, even during long sessions; Advanced eye comfort technology certified by TÜV reduces eye strain by minimizing blue light and reducing irritating screen flicker²
  • INCREASED VERSATILITY: Connect to more; Plug devices straight into your monitor for increased flexibility, making your computing environment even more convenient
  • priority on the LCP image to prioritize its request.
  • Default lazy loading for other images that do not need to load immediately.

See Angular’s image optimization guide and NgOptimizedImage API reference for the documented behavior.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Can I disable the NG0913 warnings?

Yes. Angular documents two separate root-level IMAGE_CONFIG options: disableImageSizeWarning suppresses the oversized-image warning, and disableImageLazyLoadWarning suppresses the lazy-loaded-LCP warning. Both fields are booleans, as specified in the ImageConfig API. Disabling a warning hides the diagnostic; it does not change the image dimensions or loading behavior that prompted it. The NG0913 page documents the warning configuration.

Best Value
Sale
Sceptre New 22-Inch Gaming Monitor, FHD 1080p, Up to 144Hz, HDMI, DisplayPort, Built-in Speakers, Machine Black (E225W-FW144 Series, 2026)
  • 【INTEGRATED SPEAKERS】Whether you're at work or in the midst of an intense gaming session, our built-in speakers provide rich and seamless audio, all while keeping your desk clutter-free.
  • 【EASY ON THE EYES】 Protect your eyes and enhance your comfort with Blue-Light Shift technology. This feature reduces harmful blue light emissions from your screen, helping to alleviate eye strain during long hours of use and promoting healthier viewing habits.
  • 【WIDEN YOUR PERSPECTIVE】Our sleek minimal bezel design ensures undivided attention. The nearly bezel-free display seamlessly connects in a dual monitor arrangement, delivering an unobstructed view that lets you focus on more at once, completely distraction-free.

Is NG0913 an Angular compiler diagnostic?

No. NG0913 is an image-related runtime warning. Angular’s extended diagnostics are a separate compiler feature for code patterns that may be valid but have caveats. They emit when strictTemplates is enabled, are warnings by default, and can be individually set to warning, error, or suppress. Angular also notes that a minor release may add or enable diagnostics, so an upgrade can surface new compiler warnings. Those extended-diagnostics settings do not configure NG0913. See the extended diagnostics overview.

Does fixing NG0913 solve all Angular performance problems?

No. This warning is specifically about image sizing and loading priority. For broader runtime slowness, profile the application to locate the actual bottleneck rather than treating NG0913 as a general performance diagnosis. Angular’s performance overview distinguishes loading performance from runtime responsiveness and describes Chrome DevTools and Angular DevTools as profiling options.

For runtime issues, Angular’s runtime performance guidance discusses change-detection frequency and related causes. Its slow computations guide explains that template expressions and certain lifecycle hooks run synchronously during change detection, so an expensive computation can slow the cycle. Profile first, then investigate the measured source of the slowdown.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
PC Slower Than It Used to Be?Free scan - under a minute
Outdated Drivers Are Slowing You DownFree scan - exact matches

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.