---
title: "Automatically remove HTML comments in Release mode"  
description: "Automatically remove HTML comments in Release mode"  
author: "Lillian Martin"  
published: 2015-01-29  
updated: 2015-01-29  
canonical: https://www.mindstick.com/forum/12916/automatically-remove-html-comments-in-release-mode  
category: "asp.net"  
tags: ["html", "asp.net mvc"]  
reading_time: 1 minute  

---

# Automatically remove HTML comments in Release mode

I [am trying](https://answers.mindstick.com/qa/36834/which-two-programming-languages-should-i-master-in-if-i-am-trying-to-get-into-google-or-facebook) to find a way to automatically remove HTML [comments](https://www.mindstick.com/news/2328/deadline-for-comments-on-the-draught-indian-telecommunication-bill-is-extended-by-the-dot) in [release](https://www.mindstick.com/news/2247/apple-plans-to-release-new-macs-in-early-2023) mode for two main [reasons](https://www.mindstick.com/articles/13029/top-4-reasons-to-try-online-casinos)

- Minification: there is a lot of comments in some pages
- Comments contain [development](https://www.mindstick.com/articles/65309/importance-of-ux-design-in-the-development-of-mobile-apps) notices and TODO lists (which are exposed to end user).

I am using [ASP.NET MVC](https://www.mindstick.com/forum/155798/what-is-caching-in-asp-dot-net-mvc) and looking for something in the same spirit as the [bundling and minification](https://www.mindstick.com/forum/12842/how-to-transform-styles-urls-to-cdn-urls-in-asp-dot-net-bundling-and-minification) features.

## Replies

### Reply by Anurag Sharma

@*

This is a server side

multiline comment

*@


---

Original Source: https://www.mindstick.com/forum/12916/automatically-remove-html-comments-in-release-mode

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
