> ## Documentation Index
> Fetch the complete documentation index at: https://voltaire.tevm.sh/llms.txt
> Use this file to discover all available pages before exploring further.

# Hardfork.isAfter

> Check if hardfork is after a target version (strictly greater than)

<Card title="Try it Live" icon="play" href="https://playground.tevm.sh?example=primitives/hardfork.ts">
  Run Hardfork examples in the interactive playground
</Card>

<Tabs />

## Usage Patterns

### Version Detection

Check for newer versions:

```typescript theme={null}
import { Hardfork, CANCUN } from 'tevm'

const fork = Hardfork(config.hardfork)

if (fork.isAfter(CANCUN)) {
  console.log("Running post-Cancun hardfork with unknown features")
  console.log("Consider upgrading documentation")
}
```

### Feature Availability

Check for features beyond a certain version:

```typescript theme={null}
import { Hardfork, SHANGHAI } from 'tevm'

function hasNewFeatures(fork: BrandedHardfork): boolean {
  // Check if this is a newer hardfork with additional features
  return fork.isAfter(SHANGHAI)
}
```

### Network Configuration

Validate forward compatibility:

```typescript theme={null}
import { Hardfork, PRAGUE } from 'tevm'

function validateTestnetConfig(fork: BrandedHardfork) {
  if (fork.isAfter(PRAGUE)) {
    console.warn(
      `Hardfork ${Hardfork.toString(fork)} is newer than Prague. ` +
      `Some features may not be fully tested.`
    )
  }
}
```

## Chronological Ordering

Uses chronological deployment order:

```
LONDON (11) < MERGE (14) < SHANGHAI (15) < CANCUN (16) < PRAGUE (17)
```

## Strict Inequality

**Important:** `isAfter` returns false when versions are equal:

```typescript theme={null}
import { CANCUN } from 'tevm'

CANCUN.isAfter(CANCUN)  // false - not strictly after itself
```

For "greater than or equal", use [isAtLeast](/primitives/hardfork/is-at-least) or [gte](/primitives/hardfork/gte):

```typescript theme={null}
import { CANCUN, LONDON } from 'tevm'

// Greater than or equal
CANCUN.isAtLeast(CANCUN)     // true
CANCUN.gte(CANCUN)           // true

// Strictly greater than
CANCUN.isAfter(CANCUN)       // false
CANCUN.isAfter(LONDON)       // true
```

## Performance

**Time Complexity:** O(1) - Array index comparison

**Typical Time:** \~10-20ns per call

## See Also

* [isAtLeast](/primitives/hardfork/is-at-least) - Check if greater than or equal
* [isBefore](/primitives/hardfork/is-before) - Check if strictly less than
* [gt](/primitives/hardfork/gt) - Alias for isAfter (greater than)
* [gte](/primitives/hardfork/gte) - Greater than or equal
