Skip to Content
ARCUI

Header

ARCUI screen header with title alignment, built-in back behavior, actions, custom end content, safe-area integration, and accessible controls.

Header owns common screen-header semantics without requiring each screen to rebuild back behavior, action controls, and safe-area handling.

Usage

import { Header } from "react-native-arc-ui";

<Header title="Settings" />;

Back behavior

Header resolves back behavior from either:

  • local onBack;
  • provider-level ARCUI onBack.

When showBack is omitted, the built-in back control appears automatically when either callback exists.

<Header title="Details" onBack={() => navigation.goBack()} />

Set showBack={false} to suppress it explicitly.

The built-in back accessibility label falls back to ARCUI's localized provider string. backAccessibilityLabel and backAccessibilityHint are explicit per-instance overrides.

Actions

<Header
  title="Project"
  actions={[
    {
      icon: "search",
      accessibilityLabel: "Search project",
      onPress: openSearch,
    },
    {
      icon: "info",
      accessibilityLabel: "Project information",
      onPress: openProjectInfo,
    },
  ]}
/>

Header actions are icon-only controls and therefore require accessibilityLabel.

THeaderAction:

FieldTypeDescription
iconTIconTypeARCUI icon rendered inside the action control.
onPress() => voidActivation callback.
accessibilityLabelstringRequired accessible name.
accessibilityHintstringOptional additional application-specific guidance.
disabledbooleanDisable this action.
testIDstringStable action test ID.
Example
ARCUI Header back and action controls

Custom end content

actions and endContent are mutually exclusive.

<Header title="Profile" endContent={<Avatar />} />

Custom end content is consumer-owned, including interaction and accessibility behavior.

Title content and alignment

title accepts textual or arbitrary ReactNode content. Textual content receives ARCUI Header typography and accessibility semantics.

<Header title="Library" titleAlign="start" />

For mathematical centering between equal logical sides:

<Header
  title="Library"
  titleAlign="center"
  centerSideMinWidth={48}
/>

centerSideMinWidth exists only in centered mode and is mainly useful when arbitrary end content requires extra reserved side width.

Example
ARCUI Header title alignment

Geometry and motion

  • minHeight controls toolbar content height excluding safe-area padding;
  • titleNumberOfLines controls ARCUI-rendered textual title truncation;
  • showBorder defaults to true;
  • controlRadius overrides tokens.radius.headerControl;
  • controlAnimation overrides the global ARCUI press animation for built-in controls.

Safe area

Header reads ARCUI runtime insets and tokens.safeArea.header. Supply real device insets at the root provider.

Safe area & overlays →

Native surface

Header inherits supported ViewProps except children/style ownership that conflicts with its contract. style remains available on the root container and ref exposes the native View.

Testing

Use testID where the public component contract exposes it so application tests can target the ARCUI-owned root without depending on visual implementation details. Component-specific stable descendants may use documented suffixes.

For provider setup and the dedicated react-native-arc-ui/testing entrypoint, see Testing.

API Reference

Header Start Title · variant 1

Also inherits: ViewProps

PropTypeDefaultDescription
ref?Ref<View>—React 19 ref-as-prop.
title?ReactNode—Header title. Textual ReactNode content receives ARCUI Header typography and accessibility semantics. Arbitrary ReactNode content is rendered as consumer-owned custom content.
colors?Readonly<IHeaderColors>—Per-instance ARCUI-owned color overrides.
minHeight?numbertokens.sizings.header.minHeightMinimum height of the toolbar content area, excluding safe-area padding.
titleNumberOfLines?numbertokens.sizings.header.numberOfLinesMaximum number of lines for ARCUI-rendered textual titles. Custom ReactNode titles own their own text behavior.
showBack?boolean—Controls whether the built-in back action is shown. When omitted, Header automatically shows it if either a local onBack or ARCUI-level onBack callback exists.
onBack?() => void—Overrides the ARCUI-level onBack callback for this Header.
backAccessibilityLabel?string—Accessibility label for the built-in back control. When omitted, Header uses ARCUI's configured back label.
backAccessibilityHint?string—Optional additional accessibility guidance for the back control.
showBorder?booleantrueWhether to render the semantic bottom border.
controlRadius?numbertokens.radius.headerControlBorder radius of built-in back and action controls.
controlAnimation?TPressAnimationtokens.pressAnimation.typePress feedback used by built-in back and action controls. When omitted, Header uses the global ARCUI press animation.
style?StyleProp<ViewStyle>——
actions?readonly THeaderAction[]—Built-in icon actions rendered at the logical end of the Header.
titleAlign?"start""start"Aligns the title to the logical start of its available content.

Header Center Title · variant 1

Also inherits: ViewProps

PropTypeDefaultDescription
ref?Ref<View>—React 19 ref-as-prop.
title?ReactNode—Header title. Textual ReactNode content receives ARCUI Header typography and accessibility semantics. Arbitrary ReactNode content is rendered as consumer-owned custom content.
colors?Readonly<IHeaderColors>—Per-instance ARCUI-owned color overrides.
minHeight?numbertokens.sizings.header.minHeightMinimum height of the toolbar content area, excluding safe-area padding.
titleNumberOfLines?numbertokens.sizings.header.numberOfLinesMaximum number of lines for ARCUI-rendered textual titles. Custom ReactNode titles own their own text behavior.
showBack?boolean—Controls whether the built-in back action is shown. When omitted, Header automatically shows it if either a local onBack or ARCUI-level onBack callback exists.
onBack?() => void—Overrides the ARCUI-level onBack callback for this Header.
backAccessibilityLabel?string—Accessibility label for the built-in back control. When omitted, Header uses ARCUI's configured back label.
backAccessibilityHint?string—Optional additional accessibility guidance for the back control.
showBorder?booleantrueWhether to render the semantic bottom border.
controlRadius?numbertokens.radius.headerControlBorder radius of built-in back and action controls.
controlAnimation?TPressAnimationtokens.pressAnimation.typePress feedback used by built-in back and action controls. When omitted, Header uses the global ARCUI press animation.
style?StyleProp<ViewStyle>——
actions?readonly THeaderAction[]—Built-in icon actions rendered at the logical end of the Header.
titleAlign"center"requiredKeeps the title mathematically centered between equal logical sides.
centerSideMinWidth?number—Optional minimum width applied equally to both sides. Built-in back and action controls are accounted for automatically, so this is mainly useful with arbitrary endContent.

Header Start Title · variant 2

Also inherits: ViewProps

PropTypeDefaultDescription
ref?Ref<View>—React 19 ref-as-prop.
title?ReactNode—Header title. Textual ReactNode content receives ARCUI Header typography and accessibility semantics. Arbitrary ReactNode content is rendered as consumer-owned custom content.
colors?Readonly<IHeaderColors>—Per-instance ARCUI-owned color overrides.
minHeight?numbertokens.sizings.header.minHeightMinimum height of the toolbar content area, excluding safe-area padding.
titleNumberOfLines?numbertokens.sizings.header.numberOfLinesMaximum number of lines for ARCUI-rendered textual titles. Custom ReactNode titles own their own text behavior.
showBack?boolean—Controls whether the built-in back action is shown. When omitted, Header automatically shows it if either a local onBack or ARCUI-level onBack callback exists.
onBack?() => void—Overrides the ARCUI-level onBack callback for this Header.
backAccessibilityLabel?string—Accessibility label for the built-in back control. When omitted, Header uses ARCUI's configured back label.
backAccessibilityHint?string—Optional additional accessibility guidance for the back control.
showBorder?booleantrueWhether to render the semantic bottom border.
controlRadius?numbertokens.radius.headerControlBorder radius of built-in back and action controls.
controlAnimation?TPressAnimationtokens.pressAnimation.typePress feedback used by built-in back and action controls. When omitted, Header uses the global ARCUI press animation.
style?StyleProp<ViewStyle>——
endContent?ReactNode—Arbitrary consumer-owned content rendered at the logical end.
titleAlign?"start""start"Aligns the title to the logical start of its available content.

Header Center Title · variant 2

Also inherits: ViewProps

PropTypeDefaultDescription
ref?Ref<View>—React 19 ref-as-prop.
title?ReactNode—Header title. Textual ReactNode content receives ARCUI Header typography and accessibility semantics. Arbitrary ReactNode content is rendered as consumer-owned custom content.
colors?Readonly<IHeaderColors>—Per-instance ARCUI-owned color overrides.
minHeight?numbertokens.sizings.header.minHeightMinimum height of the toolbar content area, excluding safe-area padding.
titleNumberOfLines?numbertokens.sizings.header.numberOfLinesMaximum number of lines for ARCUI-rendered textual titles. Custom ReactNode titles own their own text behavior.
showBack?boolean—Controls whether the built-in back action is shown. When omitted, Header automatically shows it if either a local onBack or ARCUI-level onBack callback exists.
onBack?() => void—Overrides the ARCUI-level onBack callback for this Header.
backAccessibilityLabel?string—Accessibility label for the built-in back control. When omitted, Header uses ARCUI's configured back label.
backAccessibilityHint?string—Optional additional accessibility guidance for the back control.
showBorder?booleantrueWhether to render the semantic bottom border.
controlRadius?numbertokens.radius.headerControlBorder radius of built-in back and action controls.
controlAnimation?TPressAnimationtokens.pressAnimation.typePress feedback used by built-in back and action controls. When omitted, Header uses the global ARCUI press animation.
style?StyleProp<ViewStyle>——
endContent?ReactNode—Arbitrary consumer-owned content rendered at the logical end.
titleAlign"center"requiredKeeps the title mathematically centered between equal logical sides.
centerSideMinWidth?number—Optional minimum width applied equally to both sides. Built-in back and action controls are accounted for automatically, so this is mainly useful with arbitrary endContent.

Per-instance color slots: IHeaderColors

PropTypeDefaultDescription
background?TThemeColor——
title?TThemeColor——
border?TThemeColor——
control?Readonly<IHeaderControlColors>——

Generated from the ARCUI 2.0.0 TypeScript source snapshot. Native inherited props remain available through the referenced React Native surface.

Generated from the ARCUI 2.0.0 TypeScript source snapshot. Native inherited props remain available through the referenced React Native surface.

The generated table above covers ARCUI-owned public props from the source-aligned type snapshot. Native inherited surfaces remain available where the public type extends React Native props.

Motion

Theme color, control feedback, and relevant layout changes use ARCUI motion primitives while navigation/back/action semantics remain ordinary callbacks and React state.

See Motion for the library-wide model.

Performance

Keep application semantics at normal React update cadence. ARCUI components avoid using React state as a frame-by-frame animation driver; use the component callbacks and let Reanimated own continuous visual work.

See Performance for broader guidance.

Accessibility

ARCUI uses native roles, labels, semantic accessibility state, centralized font scaling, and localizable ARCUI-owned strings where the component owns behavior text. Consumer accessibility overrides remain available when they do not conflict with component correctness.

See Accessibility for the library-wide model.

Theming

This component resolves its normal presentation from ARCUI tokens and active theme context. Prefer token configuration for system-wide design changes and component props for genuine instance-level exceptions.

Relevant token areas include:

colors.*.header
sizings.header
border.header
typography.header
pressAnimation
animations

Top-level token overrides are shallow. Compose changed built-in namespaces from defaultTokens rather than relying on recursive merge behavior.

See Tokens and Theming.

Try it live

Open the existing React Native Snack to explore Header interactively.

Open in Expo Snack ↗

On this page