Create an Event Hub

Last updated: October 26, 2023

This guide walks you through the steps to create an Event Hub within an existing Event Hubs namespace using the Azure portal.

An Event Hub is a component of an Event Hubs namespace. You must have an Event Hubs namespace before you can create an Event Hub. If you don't have one, follow the guide to Create an Event Hubs Namespace first.

Prerequisites

  • An Azure subscription. If you don't have one, create a free account.
  • An existing Azure Event Hubs namespace.

Steps to Create an Event Hub

Using the Azure Portal

  1. Navigate to your Event Hubs Namespace:

    Sign in to the Azure portal. In the search bar at the top, type "Event Hubs namespaces" and select it from the results. Select your existing namespace from the list.

    Azure Portal showing Event Hubs Namespace list
  2. Open the Event Hubs section:

    In the left-hand menu of your namespace, under "Event Hubs", select Event Hubs.

  3. Create a new Event Hub:

    Click the + Create button at the top of the Event Hubs list.

    Azure Portal showing the Create Event Hub button
  4. Configure Event Hub settings:

    In the "Create Event Hub" pane that appears, you'll need to provide the following information:

    • Name: Enter a unique name for your Event Hub. Event Hub names must be between 1 and 256 characters and can contain only letters, numbers, hyphens, and underscores.
    • Partition Count: (Optional) Specify the number of partitions. Partitions are ordered, immutable sequences of events. The default is 2.
    • Message Retention: (Optional) Set the retention period for messages. This is the duration for which the Event Hub stores events. The default is 1 day.
    Azure Portal showing the Create Event Hub configuration form
  5. Create the Event Hub:

    Click the Create button at the bottom of the pane.

You will see a notification indicating that the Event Hub is being created. Once successful, your new Event Hub will appear in the list of Event Hubs within your namespace.

Next Steps

Get Azure Event Hubs Help