Syncing feature between editor and pdf viewer not working

You have to add -synctex=1 to the commands:

  • pdflatex -synctex=1 -interaction=nonstopmode %.tex
  • xelatex -synctex=1 -interaction=nonstopmode %.tex
  • lualatex -synctex=1 -interaction=nonstopmode %.tex

After the next compilation there is a right-click menu item titled "Go to source" (Or shortcut Ctrl+').


In my case, the option -synctex=1 was in the command line. Yet it didn't work. What fixed it is deleting a file with the extension *.synctex. After that, syncing worked perfectly. Apparently, the file was a remnant of a previous latex compilation on a different machine.