Menu
Free Pack
Download BuildMaster Free Trial

Web Forms in the Age of .NET 5+: Planning for the Long Term

by The Inedo Team, on Oct 22, 2020 4:37:25 PM

No matter what you’ve heard, ASP.NET Web Forms in the age of .NET Core and .NET 5+ are possible and will still run. You do NOT have to rewrite your Web Forms applications as MVC soon or even in the near future.

Web-Forms-NET-5-2

ASP.NET Web Forms applications will remain functional, regardless of new .NET releases. This article addresses some common concerns around the future of ASP.NET Web Forms, helping you make the best decisions for your applications, your team, and yourself.

Simply put, your ASP.NET Web Forms applications may outlive you at your organization. You should focus on planning for near- and far-future scenarios and weighing the costs and benefits of staying on aging technology.

Jump to "How to (Safely) Keep your ASP.NET Web Forms Application in the .NET 5 Era"
Jump to FAQ

Is Microsoft Getting Rid of Web Forms?

Starting in .NET 5, Microsoft’s new direction is on .NET Core, not .NET Framework, of which Web Forms is a part. It is impossible to run your ASP.NET Web Forms applications using .NET Core runtime. But this doesn’t mean Microsoft is “getting rid of Web Forms.”

Microsoft’s newer development platforms (starting with .NET 5) have a faster release cadence and a shorter lifecycle. For example, .NET 8 is scheduled for release in 2023 and will be out of support in 2026—which is sooner than .NET Framework 4.8. Technology that Microsoft releases seven years from now will be unsupported sooner than technology they released 20 years ago.

The short answer, then, is NO, they aren’t “killing” Web Forms.

Quoting from Medium contributor Matthew MacDonald:

ASP.NET Web Forms is no longer an option for new development. It’s shunned but not dead — supported as a legacy product, but finally exiled from the future of .NET. Perhaps the biggest surprise isn’t that Web Forms eventually faltered. It’s that Microsoft managed to support it while creating a replacement that will keep ASP.NET alive for decades to come.

You can continue running Web Forms applications “for decades to come” because it is tied to the operating system. And just like .NET Framework itself, Web Forms so entrenched in the .NET Framework that Microsoft will not say they’re deprecating it officially. Your Web Forms applications will continue to work as long as you have people to support them, but just like Classic ASP applications, these will become increasingly brittle the older they get.

What This Means for You

The idea of rewriting an entire, often huge ASP.NET Web Forms for MVC (or Blazor) is understandably overwhelming. It is a ton of work, time, training, and money. And there is a good chance that both developers and end-users won’t be happy with the changes and bugs that crop up after the rewrite.

Why do all this, when there’s no real urgency?

Learn from a Case-in-point: Classic ASP

To illustrate this lack of urgency, we ask: What’s it like to have a Classic ASP application today?

Some organizations still have applications on Classic ASP because “If it ain’t broke, don’t fix it!” And that0 software runs just fine. In fact, you can even use Classic ASP on Windows 10 with Azure (if you’re willing and able to do the work to make it happen).

However, in 2020, Classic ASP applications do present some risk, because they run on 20-year-old technology. These concerns include:

  • Software changes are extremely expensive and risky because very few will know how the application is coded, so when they edit the code, they could introduce new bugs
  • Hiring people to maintain that application will be nearly impossible, because very few have Classic ASP skills, so they will have to learn or relearn how it works, and they will still make mistakes.
  • If you do find people to maintain it, you’ll have pay a lot more for those staff members, because very few want to work on ancient technology instead of cool, new stuff.

How to (Safely) Keep Your ASP.NET Web Forms Application in the .NET 5 Era

1. Consider security risks.

If your Web Forms application is not exposed to the Internet, there’s little risk in maintaining an aging app. Even so, internal applications can be compromised and if a vulnerability is discovered, then you’ll have to change it. This becomes increasingly expensive as time passes.

2. Assess the amount of JavaScript and the browser types your application uses.

If your web application requires an old browser (Internet Explorer only, for example), then you’ll have to also control the desktop. This is an added cost and barrier to using the application—not a huge barrier, but not insignificant.

Try to get your ASP.NET Web Forms application working on modern web browsers to reduce the JavaScript risk. If the application runs on modern web browsers with no problem, it should work fine in the future.

3. Help train your replacement's replacement's replacement.

No, we don’t mean to break out of your nursing home to literally come in for training. Google exists, so there will almost certainly be plenty of Web Forms documentation available to developers in 20 years. What isn’t Googleable, though, is how exactly your organization uses Web Forms for each application.

Spend your time documenting what Web Forms features the application leverages and how it uses (or abuses) those features. This way, some future employee who has never heard of Web Forms can quickly learn about how to maintain that application.

The web (HTTP with HTML/CSS/JavaScript) will most certainly be familiar and likely used very similarly in 20 years. But Web Forms programming will be very unfamiliar. Spending just a few hours writing about how you're using Web Forms could save weeks of high-stress reading about 20-year-old technology that someone has to maintain in the future.

If you and your Web Forms application runs fine on modern browsers, you may never have to rewrite your application. But in case you still have questions, we answer many of the common questions about the “end” of Web Forms.

Common Concerns about ASP.NET Web Forms

What does Microsoft want us to use instead of ASP.NET Web Forms?

MVC or Blazor.

But choosing to rewrite applications to use MVC or Blazor means rewriting the entire application, retraining staff, and dealing with the UI “bumps” we’ve all experienced when organizations do behind-the-scenes updates. If your organization does not have the resources to dedicate to manage all this, rewriting at this time may not be the right choice.

Do we need to rewrite RIGHT NOW?

There is no immediate need to rewrite your Web Forms applications. Like Classic ASP, with the right staff and documentation, Web Forms applications are likely to be maintainable well into the 2030s, if not longer.

Do we need to rewrite AT ALL?

Possibly. Each application is different, so there is no simple answer. Instead, consider these factors when deciding:

  • What operating system is the application running on? (Web Forms functionality is tied to the OS.)
  • How much time/resources can you dedicate to staff (re)training time?
  • How long do you estimate it will take to rewrite the application?
  • Most importantly: What is the estimated application lifespan? If you’re writing a brand-new application that will likely last for 20 years, writing it on increasingly deteriorating technology is perhaps an unwise choice.

Should we avoid ASP.NET Web Forms for new applications?

Probably. Each application is different, so there is no simple answer. Microsoft has made it clear that .NET 5+ (the heir of .NET Core) is the future of .NET development; it's inevitable even if not immediate, so making the switch may be a good investment in your future. Also, consider these factors when deciding:

  • What operating system is the application running on? (Web Forms functionality is tied to the OS.)
  • How much time/resources can you dedicate to staff (re)training time?
  • How long do you estimate it will take to rewrite the application?
  • Most importantly: What is the estimated application lifespan? If you’re writing a brand-new application that will likely last for 20 years, writing it on increasingly deteriorating technology is perhaps an unwise choice.

Will Microsoft change their mind and bring back ASP.NET Web Forms?

Who knows! We know they’ve “rolled back” their decisions before. Remember the Windows 8-era “Universal Windows Apps” (UWPs)? Microsoft wanted those to be “the way of the future,” but developers were so dissatisfied that Microsoft reversed their decision.

Regardless, it’s better to assume Microsoft won’t change their minds on Web Forms. But because Web Forms is so entrenched in .NET Framework that it shouldn’t matter whether they roll back their plan as you make decisions for your applications.

Using All This Information to Make Decisions

The key takeaways:

  • Web Forms is NOT going away; you can keep using it. It’s already legacy; it’s just going to be a slightly greyer legacy as Microsoft shifts to .NET Core vNext with .NET 5.
  • There are many options for the mid-term and long-term available to your organization to stay with Web Forms. It’s totally fine to stay with your current application for a long time, as long as you account for increased difficulty in finding new talent to maintain it and in dealing with possible vulnerabilities that can come with age. You might say that, for ASP.NET applications, “plan for it to last 10 years, but be prepared for 20.”
  • Plan for various scenarios, always thinking in the long-term. You personally are unlikely to make these changes. But you can help your organization by thinking about the next person or even two people who will hold your position after you’ve left.

The best thing you can do is to take stock of your applications and make some rough plans. In a previous.NET article, we recommended these five steps for making a migration plan:

  1. Inventory your existing applications
  2. Assess deprecated components
  3. Prioritized with stakeholders
  4. Prepare a rough migration schedule
  5. Increase your release velocity

When it comes to ASP.NET Web Forms, focus on the first three steps. With stakeholders, create general estimates for a rewrite schedule, keeping in mind that this time may come long after you’ve retired.

In your lifetime, your ASP.NET Web Forms applications may never have to be rewritten. But thinking about and planning for the long term is a small way to contribute to the lasting success of your organization.

Making the .NET 5 Migration? Get a Copy of the .NET 5 Migration Guide

Organizations using Web Forms applications may still be considering the migration to .NET 5 from .NET Framework or Core. We’re building a guide on how to successfully migrate to .NET 5 and beyond. Sign up today to get early access and to share your own feedback and input.

Topics:NuGet.NET 5.NET Framework.NET CoreMicrosoftASP.NETWeb Forms

More...