---
title: "Configure web.config"
slug: "configure-web-config"
abstract: ""
---
# Configure web.config

Depending on your topology, add this key in the appSettings section in the Web.config file on your CD server: 

XM:
```xml
<add key="sxaxm:define" value="sxaxmonly" />
```

XP: 
```xml
<add key="sxaxm:define" value="sxaxconnect" />
```

Replace this 
```xml
<add verb="*" path="sitecore_media.ashx" type="Sitecore.Resources.Media.MediaRequestHandler, Sitecore.Kernel" name="Sitecore.MediaRequestHandler"/>
```
With this
```xml
<add verb="*" path="sitecore_media.ashx" type="Sitecore.XA.Foundation.MediaRequestHandler.MediaRequestHandler,Sitecore.XA.Foundation.MediaRequestHandler" name="Sitecore.MediaRequestHandler"/>
```