# New-HTMLInfoCard

Creates a dashboard info card with customizable styling options.

Project

PSWriteHTML

Generate HTML reports, dashboards, and emails from PowerShell without writing HTML, CSS, or JavaScript.

[View on GitHub](https://github.com/EvotecIT/PSWriteHTML) [Visit Website](#) [Releases](https://github.com/EvotecIT/PSWriteHTML/releases/tag/v1.41.0) [Changelog](#) [Get package](https://www.powershellgallery.com/packages/PSWriteHTML/1.40.0)

Stars **1,025**

Forks **114**

Open issues 

PowerShell Gallery downloads **7,576,901**

Release **v1.45.0**

Language: PowerShell Updated: 2026-11-19

Command 

**Module**

`PSWriteHTML`

Creates a dashboard info card with customizable styling options.

## Syntax

```
New-HTMLInfoCard
[-Alignment <Left|Center|Right>]
[-AnchorName <String>]
[-BackgroundColor <String>]
[-BorderRadius <String>]
[-Icon <String>]
[-IconColor <String>]
[-Number <String>]
[-NumberColor <String>]
[-ShadowBlur <Int32>]
[-ShadowColor <String>]
[-ShadowDirection <Bottom|Top|Left|Right|All>]
[-ShadowIntensity <Subtle|Normal|Bold|ExtraBold|Custom>]
[-ShadowSpread <Int32>]
[-Style <Standard|Compact|Fixed|Classic|NoIcon>]
[-Subtitle <String>]
[-SubtitleColor <String>]
-Title <String>
[-TitleColor <String>]
[<CommonParameters>]
```

[#](#method-new-htmlinfocard-string-string-string-string-string-string-string-string-int32-string-string-string-int32-string-string-string-string-string)

Parameter set: `Emoji`

```
New-HTMLInfoCard
[-Alignment <Left|Center|Right>]
[-AnchorName <String>]
[-BackgroundColor <String>]
[-BorderRadius <String>]
[-IconColor <String>]
[-Number <String>]
[-NumberColor <String>]
[-ShadowBlur <Int32>]
[-ShadowColor <String>]
[-ShadowDirection <Bottom|Top|Left|Right|All>]
[-ShadowIntensity <Subtle|Normal|Bold|ExtraBold|Custom>]
[-ShadowSpread <Int32>]
[-Style <Standard|Compact|Fixed|Classic|NoIcon>]
[-Subtitle <String>]
[-SubtitleColor <String>]
-Title <String>
[-TitleColor <String>]
[<CommonParameters>]
```

[#](#method-new-htmlinfocard-string-string-string-string-string-string-string-int32-string-string-string-int32-string-string-string-string-string)

Parameter set: `Dictionary`

```
New-HTMLInfoCard
[-Alignment <Left|Center|Right>]
[-AnchorName <String>]
[-BackgroundColor <String>]
[-BorderRadius <String>]
[-IconColor <String>]
[-IconSolid <String>]
[-Number <String>]
[-NumberColor <String>]
[-ShadowBlur <Int32>]
[-ShadowColor <String>]
[-ShadowDirection <Bottom|Top|Left|Right|All>]
[-ShadowIntensity <Subtle|Normal|Bold|ExtraBold|Custom>]
[-ShadowSpread <Int32>]
[-Style <Standard|Compact|Fixed|Classic|NoIcon>]
[-Subtitle <String>]
[-SubtitleColor <String>]
-Title <String>
[-TitleColor <String>]
[<CommonParameters>]
```

[#](#method-new-htmlinfocard-string-string-string-string-string-string-string-string-int32-string-string-string-int32-string-string-string-string-string-2)

Parameter set: `FontAwesomeSolid`

```
New-HTMLInfoCard
[-Alignment <Left|Center|Right>]
[-AnchorName <String>]
[-BackgroundColor <String>]
[-BorderRadius <String>]
[-IconColor <String>]
[-IconRegular <String>]
[-Number <String>]
[-NumberColor <String>]
[-ShadowBlur <Int32>]
[-ShadowColor <String>]
[-ShadowDirection <Bottom|Top|Left|Right|All>]
[-ShadowIntensity <Subtle|Normal|Bold|ExtraBold|Custom>]
[-ShadowSpread <Int32>]
[-Style <Standard|Compact|Fixed|Classic|NoIcon>]
[-Subtitle <String>]
[-SubtitleColor <String>]
-Title <String>
[-TitleColor <String>]
[<CommonParameters>]
```

[#](#method-new-htmlinfocard-string-string-string-string-string-string-string-string-int32-string-string-string-int32-string-string-string-string-string-3)

Parameter set: `FontAwesomeRegular`

```
New-HTMLInfoCard
[-Alignment <Left|Center|Right>]
[-AnchorName <String>]
[-BackgroundColor <String>]
[-BorderRadius <String>]
[-IconBrands <String>]
[-IconColor <String>]
[-Number <String>]
[-NumberColor <String>]
[-ShadowBlur <Int32>]
[-ShadowColor <String>]
[-ShadowDirection <Bottom|Top|Left|Right|All>]
[-ShadowIntensity <Subtle|Normal|Bold|ExtraBold|Custom>]
[-ShadowSpread <Int32>]
[-Style <Standard|Compact|Fixed|Classic|NoIcon>]
[-Subtitle <String>]
[-SubtitleColor <String>]
-Title <String>
[-TitleColor <String>]
[<CommonParameters>]
```

[#](#method-new-htmlinfocard-string-string-string-string-string-string-string-string-int32-string-string-string-int32-string-string-string-string-string-4)

Parameter set: `FontAwesomeBrands`

## Description

The New-HTMLInfoCard function creates modern, responsive dashboard cards displaying key metrics or information. It supports multiple styles including standard, compact, fixed layout (multiline-safe), and classic designs.

## Examples

### Example 1

```powershell
New-HTMLInfoCard -Title "Total Users" -Number 47 -Subtitle "21.28% of users" -Icon "👥" -IconColor "#0078d4"
```

Creates a standard info card with a user icon and blue background.

### Example 2

```powershell
New-HTMLInfoCard -Title "Sales Today" -Number 132 -Subtitle "12 waiting payments" -Style "Classic" -IconFromDictionary "Money" -IconColor "#21c87a"
```

Creates a classic style card using icon from dictionary.

### Example 3

```powershell
New-HTMLInfoCard -Title "Analytics Report" -Number 156 -Subtitle "Reports generated" -IconSolid "chart-bar" -IconColor "#6f42c1"
```

Creates a card with FontAwesome solid icon.

### Example 4

```powershell
New-HTMLInfoCard -Title "Revenue" -Number "$45,320" -Subtitle "This month" -Style "NoIcon" -Alignment "Center" -NumberColor "#21c87a"
```

Creates a centered card without an icon.

### Example 5

```powershell
New-HTMLInfoCard -Title "Server Status" -Number "Online" -Subtitle "Last check: 2 min ago" -Icon "Server" -IconColor "#28a745" -TitleColor "#2c3e50" -SubtitleColor "#7f8c8d" -ShadowColor "rgba(40, 167, 69, 0.15)"
```

Creates a card with custom title, subtitle, and shadow colors.

### Example 6

```powershell
New-HTMLInfoCard -Title "Alert" -Number "3" -Subtitle "Requires attention" -Icon "Warning" -IconColor "#dc3545" -ShadowDirection "Right" -ShadowColor "rgba(220, 53, 69, 0.2)"
```

Creates a card with a right-side red shadow for emphasis.

## Parameters

**-Alignment String optional**

Text alignment within the card. Options: - 'Left' (default): Left-aligned text - 'Center': Center-aligned text - 'Right': Right-aligned text

Possible values: `Left`, `Center`, `Right`

**-AnchorName String optional**

Optional anchor name for the card element.

**-BackgroundColor String optional**

Background color of the card. Defaults to white.

**-BorderRadius String optional**

Border radius for rounded corners. Defaults to 14px.

**-Icon String optionalsets: Emoji**

Icon to display on the card. Can be an emoji (like 👥, 🔒, 💪).

**-IconColor String optional**

Background color for the icon. Supports color names, hex codes, or RGB values.

**-Number String optional**

The primary numeric value or main statistic to display.

**-NumberColor String optional**

Color for the main number/statistic. Defaults to blue (#0078d4).

**-ShadowBlur Int32 optional**

**-ShadowColor String optional**

Color for the card shadow. Defaults to light gray (rgba(60, 60, 60, 0.08)).

**-ShadowDirection String optional**

Direction/position of the card shadow. Options: - 'Bottom' (default): Standard shadow below the card - 'Top': Shadow above the card - 'Left': Shadow to the left of the card - 'Right': Shadow to the right of the card - 'All': Shadow on all sides

Possible values: `Bottom`, `Top`, `Left`, `Right`, `All`

**-ShadowIntensity String optional**

Possible values: `Subtle`, `Normal`, `Bold`, `ExtraBold`, `Custom`

**-ShadowSpread Int32 optional**

**-Style String optional**

The visual style of the card. Options: - 'Standard' (default): Regular cards with icons on the left - 'Compact': Smaller cards with reduced padding - 'Fixed': Multiline-safe layout where numbers stay aligned - 'Classic': Traditional style with square colored icon backgrounds - 'NoIcon': Cards without any icons

Possible values: `Standard`, `Compact`, `Fixed`, `Classic`, `NoIcon`

**-Subtitle String optional**

Optional subtitle or description text below the number.

**-SubtitleColor String optional**

Color for the subtitle text. Defaults to medium gray (#666).

**-Title String required**

The main title/label text for the card.

**-TitleColor String optional**

Color for the title text. Defaults to dark gray (#222).

**-IconSolid String optionalsets: FontAwesomeSolid**

FontAwesome solid icon name.

**-IconRegular String optionalsets: FontAwesomeRegular**

FontAwesome regular icon name.

**-IconBrands String optionalsets: FontAwesomeBrands**

FontAwesome brands icon name.

## Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see [about_CommonParameters](https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_commonparameters).

Evotec API Reference Copyright 2026 Evotec Services

<!-- PowerForge markdown artifact sha256:01F82F64CE10960DF22B140A7D67F4E31B1D3E4441626716D14DE06F5502B1BF -->
