In Firefox, console.log is not showing anything

FirefoxLogging

Firefox Problem Overview


I'm trying a simple console.log function in Firefox:

console.log("Hello, World!");

You may try it on: http://jsfiddle.net/EkZjK/

You may also try the full code in a stand-alone HTML file:

<html>
    <head>
        <meta content="text/html;charset=utf-8" http-equiv="Content-Type">
        <script type="text/javascript">
            console.log("Hello World !");
        </script>
    </head>
</html>

I get console logs in Chrome.
But in Firefox I cannot see the logs.

I tried the Firebug console and Ctrl + Shift + J
. Both don't show the log message in Firefox.

PS: I restarted Firefox, restarted Windows, tried on another machine, deleted the Firefox profile and created another one, and reinstalled Firefox. But the problem still exists.

How can I solve this?

Firefox Solutions


Solution 1 - Firefox

For some previous versions of Firefox

I had the same problem with a different root cause.

Hit Ctrl + Shift + K to open the full console. In the second row from the top there are tabs - Net, CSS, JS, Security, Logging, and Server. Hit the triangle to the right of "Logging" to open the dropdown and make sure that at least "log" is on.

Enter image description here

Solution 2 - Firefox

Reinstalling the Firebug plugin solved the issue.
Now it appears in the Firebug console (not in Ctrl + Shift + J).

Solution 3 - Firefox

For Firefox 77.0.1 and Ubuntu 18.04 (Bionic Beaver) LTS (Bionic Beaver):

I had the same problem.

Open the Firefox console - Ctrl + Shift + J.

In the browser console, click on the top right settings icon. In the dropdown, click on Show Content Messages.

Then console.log messages will start showing up in the console.

Solution 4 - Firefox

  1. Uninstall Firebug (or disable it)
  2. Press F12 and enjoy the console.

The problem is Firebug. It's not maintained anymore and may be unstable (see the official page). Other users here recommend to update it, but it may not work, or work until the next Firefox update.

Solution 5 - Firefox

I had the problem again today with Chrome and Firefox. Ultimately, however, the cause was not the console, but some code in jQuery UI v1.12.1.

After I had written console.clear() after the jQuery UI code, the console outputs after this script were shown again.

Solution 6 - Firefox

I had the same problem with Firefox 75.0 on Ubuntu 18.0 (Bionic Beaver). The following solved it for me:

  1. Open the Console
  2. Click the Logs button until grey in Filter output row on the right
  3. Click the Settings gear on the right and choose in the dropdown "Persist Logs".

Solution 7 - Firefox

I recently had the same issue with Firefox. What worked for me was restarting Firefox and then adding the Console.clear() method to my script. Once the page loads up, the console logs your messages again.

Solution 8 - Firefox

I had this problem in Firefox 71, and I found that when you open the console not everything is automatically logged.

When you go to the right side of the console you see a number of buttons, (Errors, Warnings, Logs, Info, Debug, CSS, XHR, and Requests). Enable all logs by clicking these buttons.

Solution 9 - Firefox

In FireFox 90.0, Mac OS 11.4, I had to click on the Gear Icon and put a check mark next to 'Show Content Messages' before console.log output appeared on the console.

Edit: I see now this was mentioned in the fine print on one of the responses above.

Solution 10 - Firefox

I had the same problem with my browser but all you’ll have to do is to open up the console by pressing ctrl + shift + k or press the right key and press inspect then navigate to the left hand section that says logs click on it and you should be good to go

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionAshraf BashirView Question on Stackoverflow
Solution 1 - Firefox0fntView Answer on Stackoverflow
Solution 2 - FirefoxAshraf BashirView Answer on Stackoverflow
Solution 3 - FirefoxAseemView Answer on Stackoverflow
Solution 4 - FirefoxfreskoView Answer on Stackoverflow
Solution 5 - Firefoxuser9657261View Answer on Stackoverflow
Solution 6 - FirefoxHmerman6006View Answer on Stackoverflow
Solution 7 - FirefoxViceodevView Answer on Stackoverflow
Solution 8 - FirefoxFreezeView Answer on Stackoverflow
Solution 9 - FirefoxTundraGreenView Answer on Stackoverflow
Solution 10 - FirefoxTravonView Answer on Stackoverflow