---
title: "invalid-time-layout"
description: "Detect invalid time.Parse layouts."
image: "https://strider.gempir.com/og.png"
---

> Documentation Index
> Fetch the complete documentation index at: https://strider.gempir.com/llms.txt
> Use this file to discover all available pages before exploring further.

# invalid-time-layout

**Default severity:** `error`

Validates constant layouts against Go's reference-time convention.

## Bad

```go
time.Parse("YYYY-MM-DD", value)
```

## Good

```go
time.Parse("2006-01-02", value)
```

Source: https://strider.gempir.com/analyzers/invalid-time-layout/index.mdx
