this is rather simple. just create a catch-all route
get '*path', to: 'tags#new'
the requested part will be params[:path]
i would recommend not having unscoped catch-all routes through. it's slow and a pita if you ever want to change your URL structure (you will want to do that at some point). always use some namespace www.some-url.com/t/xyz123