Azure & RAG Beginner Friendly 4 Parts · ~30 min

How to Set Up Azure AI Search for a RAG Pipeline

A complete walkthrough — from a fresh Azure account to a deployed embedding model — giving you the full retrieval backbone for an agentic or RAG project.

Download PDF Guide ← All Guides

What You Will Build

Most RAG tutorials skip the part that actually trips people up: the cloud setup. This guide walks through every screen in the Azure portal so you can stand up the retrieval layer for an agentic project without guessing.

Who It's For

Developers and students building their first retrieval-augmented or agentic application on Azure, especially those working in OutSystems and ODC.

What You'll Set Up

A free Azure account, a resource group, an AI Search service with a vector index, and a deployed text-embedding-3-small model.

What You'll Walk Away With

Six credentials: two endpoints, two keys, an index name, and a deployment name. Drop them into your application and your pipeline can retrieve.

Sign Up for a Free Azure Account

Before you can build anything, you need a verified Azure subscription. This part gets you from zero to a working portal with $200 in free credits.

1

Sign Up or Log In at portal.azure.com

Open portal.azure.com in your browser. If you already have a Microsoft account, log in. If not, start the sign-up flow from the welcome screen.

2

Click "Start with an Azure Free Trial"

On the landing screen, select the first card — Start with an Azure free trial — to begin the free trial path.

3

Create Your Azure Free Account

Click the second card — Azure free account — to create a brand-new free account with $200 credit valid for 30 days.

4

Enter Your Details

Provide your name, email address, phone number, and address, then click Next through each step.

5

Add a Payment Method and Sign Up

Enter your credit card information, click Next, and complete sign-up.

⚠️ Azure requires a payment method only for verification. You are not charged unless you create billable resources or upgrade to Pay-As-You-Go. As a precaution, use a spare card and set low domestic and international transaction limits to avoid accidental charges.
6

Enable Multi-Factor Authentication

If prompted to enable MFA, go ahead and set it up. It keeps the account secure and is increasingly required by Azure.

7

Land on the Azure Home Page

You should be redirected to portal.azure.com/home and see the welcome message. Your subscription is now live.

Create a New Resource Group

A resource group is a container that holds everything for this project, so billing, access control, and clean-up stay in one place. Always group related Azure resources together.

1

Open Resource Groups

From the left-side panel of the Azure portal home page, click Resource groups.

2

Create a New Resource Group

Click Create (or the + Create button at the top) to start a fresh resource group.

3

Name It and Create

Fill out the form with the following settings, then click Review + Create:

  • Subscription — Azure subscription 1
  • Resource group name — e.g. azure-ai-resource-group
  • Region — (US) East US

Create the Azure AI Search Service and Index

This is the retrieval backbone of your RAG pipeline. You will provision the search service, then define an index that stores both text and 1536-dimension vector embeddings.

1

Create a Resource

From the home page, click Create a resource in the left-side panel.

2

Find Azure AI Search

In the search bar, type AI Search and select Azure AI Search from the Marketplace results.

3

Fill Out the Service Form

Configure the new AI Search service with these settings:

  • Select your Subscription
  • Select the resource group you just created
  • Give a unique service name (e.g. lowcademy-search-service)
  • Set Location to (US) East US
  • Set Pricing tier to FREE
  • Click Review + Create
  • Wait 2–3 minutes for deployment to complete
4

Open the New Search Service

Go back to the home page, search for the search service you just created, and open it. You should see the service Overview with the URL shown in Essentials.

5

Go to Indexes

In the left navigation of your search service, under Search management, click Indexes to create a new index.

6

Add an Index via JSON

Click + Add indexAdd index (JSON) to open the JSON editor.

7

Paste the Index Definition and Save

Paste the JSON below into the JSON box and click Save. This defines your fields, the 1536-dimension vector field for embeddings, the semantic configuration, and the HNSW vector search profile.

{
  "name": "ai-search-index",
  "fields": [
    {
      "name": "id",
      "type": "Edm.String",
      "key": true,
      "searchable": false,
      "filterable": false,
      "retrievable": true,
      "stored": true,
      "sortable": false,
      "facetable": false
    },
    {
      "name": "tenant_id",
      "type": "Edm.Int64",
      "searchable": false,
      "filterable": true,
      "retrievable": true,
      "stored": true,
      "sortable": true,
      "facetable": false
    },
    {
      "name": "document_id",
      "type": "Edm.Int64",
      "searchable": false,
      "filterable": true,
      "retrievable": true,
      "stored": true,
      "sortable": true,
      "facetable": false
    },
    {
      "name": "sourceName",
      "type": "Edm.String",
      "searchable": false,
      "filterable": true,
      "retrievable": true,
      "stored": true,
      "sortable": true,
      "facetable": false
    },
    {
      "name": "section",
      "type": "Edm.String",
      "searchable": false,
      "filterable": true,
      "retrievable": true,
      "stored": true,
      "sortable": true,
      "facetable": false
    },
    {
      "name": "content",
      "type": "Edm.String",
      "searchable": true,
      "filterable": false,
      "retrievable": true,
      "stored": true,
      "sortable": false,
      "facetable": false
    },
    {
      "name": "embedding",
      "type": "Collection(Edm.Single)",
      "searchable": true,
      "retrievable": true,
      "stored": true,
      "dimensions": 1536,
      "vectorSearchProfile": "default-vector-profile"
    }
  ],
  "scoringProfiles": [],
  "suggesters": [],
  "analyzers": [],
  "normalizers": [],
  "tokenizers": [],
  "tokenFilters": [],
  "charFilters": [],
  "similarity": {
    "@odata.type": "#Microsoft.Azure.Search.BM25Similarity"
  },
  "semantic": {
    "configurations": [
      {
        "name": "default",
        "rankingOrder": "BoostedRerankerScore",
        "prioritizedFields": {
          "titleField": { "fieldName": "section" },
          "prioritizedContentFields": [ { "fieldName": "content" } ],
          "prioritizedKeywordsFields": [ { "fieldName": "sourceName" } ]
        }
      }
    ]
  },
  "vectorSearch": {
    "profiles": [
      { "name": "default-vector-profile", "algorithm": "default-hnsw" }
    ],
    "algorithms": [
      { "name": "default-hnsw", "kind": "hnsw" }
    ]
  }
}
💡
Why 1536 dimensions? The text-embedding-3-small model outputs 1536-dimension vectors. The index field must match this dimension count exactly for vector search to work.
8

Verify the Index Fields

After saving, open the newly created index, go to the Fields tab, and confirm the fields match the JSON you pasted — including the embedding field with dimension 1536.

Your AI Search index is ready once you see all 7 fields listed correctly.
9

Grab the URL and Admin Key

You now need two values from this service:

  • URL — visible on the search service Overview page (format: https://<name>.search.windows.net). Copy and save it.
  • Admin key — go to Security + Networking › Keys and copy the Primary admin key.

Create the Azure OpenAI Resource for Embeddings

Retrieval needs vectors. Here you provision Azure OpenAI and deploy the embedding model that turns your text into the 1536-dimension vectors your index expects.

1

Find Azure OpenAI

  • From the portal search bar, type OpenAI
  • Click Azure OpenAI from the results
2

Create the Resource

  • Click Create → choose Azure OpenAI
  • Fill the form: select your subscription, resource group, set a unique name, choose region (US) Central US, pricing tier Standard S0
  • Click Next through Network and Tags, then click Create
  • Wait 3–4 minutes for the deployment to complete
3

Open the Foundry Portal

  • Open the newly created Azure OpenAI resource
  • Click Go to Foundry portal
4

Open the Model Catalog

In the Foundry portal, under the new resource, open the Model catalog.

⚠️ If the Foundry portal sends you to the new experience, switch back to the old one for these steps. The model catalog navigation may differ in the new Foundry experience.
5

Search for the Embedding Model

In the model catalog search box, type text-embedding-3-small and select it from the results. You should see it listed under Embeddings.

6

Select the Model

  • Select text-embedding-3-small
  • Click Use this model
7

Deploy the Model

Configure the deployment with these settings:

  • Deployment nametext-embedding-3-small
  • Deployment type — Standard
  • Resource location — East US 2 (pre-selected)
  • Click Create resource and deploy
8

Understand What Just Happened

Go to Overview and check the resources. You will likely see two Azure OpenAI resources.

Original resource
  • • Billing
  • • Access control (IAM)
  • • Monitoring
  • • Azure portal management
Auto-created Foundry resource
  • • Model deployments
  • • Endpoint URL
  • • API keys

Go to the second (Foundry-created) resource, navigate to Models & Endpoints, and copy the Endpoint URL and API key. Use these in your application for embedding requests.

9

Get Your Endpoint and Key

From the Foundry-created resource's deployment page, copy the following three values:

Endpoint https://<foundry-resource-name>.cognitiveservices.azure.com/
Deployment name text-embedding-3-small
Key <your key>

Your Six Credentials

You should now have all six values ready. Drop them into your application — your RAG pipeline can retrieve.

Azure AI Search Endpoint
https://<name>.search.windows.net
Azure AI Search Admin Key
<your primary admin key>
Azure AI Search Index Name
ai-search-index
Azure OpenAI Endpoint
https://<foundry-name>.cognitiveservices.azure.com/
Azure OpenAI Key
<your key from Models & Endpoints>
Embedding Deployment Name
text-embedding-3-small
You're done. Your Azure AI Search index is ready for vector ingestion and the text-embedding-3-small model is deployed and live. The next step is to start feeding your documents in — chunk, embed, and upload to the index.

Download the Full PDF Guide

All 30 pages — every step, every screenshot. Save it offline or share with your team.

Download PDF