# Angular Material — Material Design Components for Angular > Official Material Design UI component library for Angular applications, maintained by the Angular team at Google. ## Install Save in your project root: # Angular Material — Material Design Components for Angular ## Quick Use ```bash ng new my-app && cd my-app ng add @angular/material # Import a module in your component: import { MatButtonModule } from '@angular/material/button'; ``` ## Introduction Angular Material is the official component library implementing Google's Material Design specification for Angular. It provides production-ready, accessible UI components that integrate with Angular's forms, routing, and dependency injection systems out of the box. ## What Angular Material Does - Provides 30+ pre-built UI components following Material Design guidelines - Implements WAI-ARIA accessibility patterns across all components - Integrates with Angular CDK for layout, drag-and-drop, and virtual scrolling - Supports theming with custom color palettes and typography - Offers bidirectional text and internationalization support ## Architecture Overview Angular Material is built on top of the Angular Component Dev Kit (CDK), which provides behavior primitives without imposing visual style. Each Material component wraps CDK behaviors with Material Design styling and animations. The theming system uses Sass mixins that generate CSS custom properties, allowing runtime theme switching. Components use Angular's change detection and dependency injection natively. ## Self-Hosting & Configuration - Add via `ng add @angular/material` which configures styles and animations - Choose a prebuilt theme or define a custom theme in your global stylesheet - Import only the modules you need to keep bundle size minimal - Configure density and typography scales through Sass variables - CDK modules like overlay and a11y are available independently ## Key Features - Fully accessible with keyboard navigation and screen reader support - Tree-shakable modules keep production bundles lean - Theming system supports light/dark modes and custom palettes - CDK provides headless primitives for custom component development - Maintained and tested against every Angular release by the core team ## Comparison with Similar Tools - **PrimeNG** — Larger component set but heavier bundle, community-driven - **Ant Design (ng-zorro)** — Enterprise-oriented, follows Ant Design spec instead of Material - **Clarity** — VMware design system, web-component based, now archived - **Bootstrap (ng-bootstrap)** — Bootstrap styling, not Material Design - **Taiga UI** — Modern Angular library with smaller community ## FAQ **Q: Is Angular Material compatible with standalone components?** A: Yes. All components support Angular's standalone API starting from v15. **Q: Can I customize the theme colors?** A: Yes. Define a custom theme using Sass by providing primary, accent, and warn palettes to the theming mixins. **Q: Does it support server-side rendering?** A: Yes. Angular Material works with Angular Universal for SSR without additional configuration. **Q: How does Angular CDK relate to Angular Material?** A: CDK provides unstyled behavior primitives (overlays, drag-drop, virtual scroll). Material components are built on top of CDK, adding Material Design styling. ## Sources - https://github.com/angular/components - https://material.angular.io/ --- Source: https://tokrepo.com/en/workflows/angular-material-material-design-components-angular-9dab86ec Author: AI Open Source