# RESTful unique subdomains

**URL:** <https://www.ruby-forum.com/t/restful-unique-subdomains/106133>\
**Category:** Rails\
**Created:** [June 6, 2007, 7:27pm UTC](https://www.ruby-forum.com/t/restful-unique-subdomains/106133 "2007-06-06T19:27:33Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![guest](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/8dc957/32.png) [@guest](https://www.ruby-forum.com/u/guest)\
**Post date:** [June 6, 2007, 7:27pm UTC](https://www.ruby-forum.com/t/restful-unique-subdomains/106133/1 "2007-06-06T19:27:33Z")

</div>

Does anyone know the best way to handle arbitrary sub domains based on  
user selection RESTfully?

In other words, in our app we’re going to let the user select a sub  
domain, and need that to resolve to our main Rails app and use that as  
the key for their account. Navigating to the subdomain  
([userselected.oururl.com](http://userselected.oururl.com)) will call the show action of the account  
controller.

And we’re going to be using RESTful routes as well. Is there a plugin  
perhaps? The request\_routing plugin doesn’t seem to work with REST, and  
I’m not sure if that’s the best fit for this.

Thanks for any help.
