<!-- language-all: none -->
*<sup>Note: Though my original answer attracted several upvotes, I decided that I could do much better. You can find my original (simplistic and misguided) answer in the edit history.</sup>*
If Microsoft had the intent of providing a means of outputting a blank line from `cmd.exe`, Microsoft surely would have documented such a simple operation. It is this omission that motivated me to ask this question.
So, because a means for outputting a blank line from `cmd.exe` is *not* documented, arguably one should consider any suggestion for how to accomplish this to be a *hack*. That means that there is no known method for outputting a blank line from `cmd.exe` that is *guaranteed* to work (or work efficiently) in *all* situations.
With that in mind, here is a discussion of methods that have been recommended for outputting a blank line from `cmd.exe`. All recommendations are based on variations of the `echo` command.
---
echo.
While this will work in many if not most situations, ***it should be avoided*** because it is slower than its alternatives and actually can fail (see [here][1], [here][2], and [here][3]). Specifically, `cmd.exe` first searches for a file named `echo` and tries to start it. If a file named `echo` happens to exist in the current working directory, `echo.` will fail with:
'echo.' is not recognized as an internal or external command,
operable program or batch file.
---
echo:
echo\
At the end of [this answer](
[To see links please register here]
), the author argues that these commands can be slow, for instance if they are executed from a network drive location. A specific reason for the potential slowness is not given. But one can infer that it may have something to do with accessing the file system. (Perhaps because `:` and `\` have special meaning in a Windows file system path?)
However, some may consider these to be safe options since `:` and `\` cannot appear in a file name. For that or another reason, `echo:` is recommended by SS64.com [here][4].
---
echo(
echo+
echo,
echo/
echo;
echo=
echo[
echo]
[This lengthy discussion](
[To see links please register here]
) includes what I believe to be all of these. Several of these options are recommended in [this SO answer](
[To see links please register here]
) as well. Within the cited discussion, [this post](
[To see links please register here]
) ends with what appears to be a recommendation for `echo(` and `echo:`.
My question at the top of this page does not specify a version of Windows. My experimentation on Windows 10 indicates that *all* of these produce a blank line, regardless of whether files named `echo`, `echo+`, `echo,`, ..., `echo]` exist in the current working directory. (Note that my question predates the release of Windows 10. So I concede the possibility that older versions of Windows may behave differently.)
In [this answer](
[To see links please register here]
), [@jeb][5] asserts that `echo(` *always* works. To me, @jeb's answer implies that other options are less reliable but does not provide any detail as to why that might be. Note that @jeb contributed much valuable content to other references I have cited in this answer.
---
**Conclusion:** Do *not* use `echo.`. Of the many other options I encountered in the sources I have cited, the support for these two appears most authoritative:
echo(
echo:
But I have not found any strong evidence that the use of either of these will always be trouble-free.
---
**Example Usage:**
@echo off
echo Here is the first line.
echo(
echo There is a blank line above this line.
**Expected output:**
Here is the first line.
There is a blank line above this line.
[1]:
[To see links please register here]
[2]:
[To see links please register here]
[3]:
[To see links please register here]
[4]:
[To see links please register here]
[5]:
[To see links please register here]