---
title: "How to change url using url routing in mvc?"  
description: "How to change url using url routing in mvc?"  
author: "Manoj Pandey"  
published: 2015-02-21  
updated: 2015-02-21  
canonical: https://www.mindstick.com/forum/12971/how-to-change-url-using-url-routing-in-mvc  
category: "asp.net mvc"  
tags: ["url rewriting", "url routing", "routing"]  
reading_time: 1 minute  

---

# How to change url using url routing in mvc?

Hi I’m working with [url routing](https://www.mindstick.com/articles/1573/url-routing-in-mvc-4).

My [question](https://www.mindstick.com/blog/23175/how-to-solve-neet-question-paper-in-less-time) is my actual [controller](https://www.mindstick.com/blog/273/passing-values-from-controller-to-view-in-asp-dot-net-mvc) is **Home** and [action](https://www.mindstick.com/forum/155752/what-is-action-result-with-its-types) is [Index](https://www.mindstick.com/blog/198/index-in-sql-server) when run [application](https://www.mindstick.com/articles/12824/calculator-application-in-android) give the appropriate [result](https://www.mindstick.com/blog/12011/advantages-of-getting-result-oriented-seo-from-an-agency) that time url is **Home/Index.**

But I’m want to when type url **[Dashboard](https://answers.mindstick.com/qa/34007/reports-and-dashboard-limitations-in-salesforce)/Index** that time [execute](https://www.mindstick.com/interview/49/how-can-i-execute-a-php-script-using-command-line) Home controller index method.

How to possible.

[Thank you in advance](https://answers.mindstick.com/qa/40482/why-was-1968-a-year-of-tension-and-turmoil-list-10-events-1-being-the-best-and-10-the-worst-thank-you-in-advance).

## Replies

### Reply by Tom Cruser

Just add this route in RouteConfig.cs file make sure to add this before default route otherwise this is not work.

```
routes.MapRoute(                 name: "OldURL",                 url: "Dashboard/{action}/{id}",                 defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional }             );
```


---

Original Source: https://www.mindstick.com/forum/12971/how-to-change-url-using-url-routing-in-mvc

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
