Title: Multisite mod_rewrite rules
Last modified: August 21, 2016

---

# Multisite mod_rewrite rules

 *  [Tomi K](https://wordpress.org/support/users/tomik/)
 * (@tomik)
 * [12 years, 9 months ago](https://wordpress.org/support/topic/multisite-mod_rewrite-rules/)
 * I have a WP multisite installed in domain.com/wp and it is intended for microsites
   my company has. There’s a non-Wordpress -site installed in domain.com and it 
   cannot be moved, neither can I install WP to the root directory.
 * **The problem:**
    I’d like to create shorter URLs for the microsites with Apache’s
   mod_rewrite. For example domain.com/site1 (that’s actually located in domain.
   com/wp/site1) would fetch the data from domain.com/wp/site1 while still maintaining
   the URL as domain.com/site1 in the browser’s URL field like this: – Browser: 
   domain.com/site1/frontpage, actual data: domain.com/wp/site1/frontpage/ – Browser:
   domain.com/site1/fruits/apple, actual data: domain.com/wp/site1/fruits/apple
 * **Question**
    Is it possible to somehow “pipe” the mod_rewrite -rules so that.
   htaccess in the root -directory would just remap the url domain.com/site1 to 
   domain.com/wp and then WP’s .htaccess would take over from there? If not, how
   could I achieve functionality like this?

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [The API Guys](https://wordpress.org/support/users/pbarthmaier/)
 * (@pbarthmaier)
 * [12 years, 9 months ago](https://wordpress.org/support/topic/multisite-mod_rewrite-rules/#post-4055927)
 * This sounds more like a CNAME.
 *  Thread Starter [Tomi K](https://wordpress.org/support/users/tomik/)
 * (@tomik)
 * [12 years, 9 months ago](https://wordpress.org/support/topic/multisite-mod_rewrite-rules/#post-4055933)
 * Unfortunately I can’t access CNAME records, so it’s got to be done with mod_rewrite
   or some other way.
 * I have access to virtual hosts and can make subdomains. Would it be possible 
   to create site1.domain.com that points to domain.com/wp/site1 ?
 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [12 years, 9 months ago](https://wordpress.org/support/topic/multisite-mod_rewrite-rules/#post-4055939)
 * This probably isn’t much help, but here’s what I know about mapping subdomains
   and vhosts and multisite.
 * When you map domains with multisite, you tell your vhosts to point to wherever
   domain.com is installed (so for me /home/me/public_html) and then let WP handle
   the rest of the magic, because it has to talk back to itself.
 * When you do subdomains, you do the same thing. site.domain.com is tossed on /
   home/me/public_html
 * I don’t know why mapping a sub-subfolder won’t work, but I know it doesn’t :/

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Multisite mod_rewrite rules’ is closed to new replies.

## Tags

 * [apache](https://wordpress.org/support/topic-tag/apache/)
 * [mod_rewrite](https://wordpress.org/support/topic-tag/mod_rewrite/)
 * [multisite](https://wordpress.org/support/topic-tag/multisite/)

 * In: [Networking WordPress](https://wordpress.org/support/forum/multisite/)
 * 3 replies
 * 3 participants
 * Last reply from: [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * Last activity: [12 years, 9 months ago](https://wordpress.org/support/topic/multisite-mod_rewrite-rules/#post-4055939)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
