222

I want to compare values from two different files.
In Notepad++ version 5.0.3 we had shortcut button Alt+d but in version 6.6.8 I cannot find any option to compare.

Also let me know which version is most stable.

0

8 Answers 8

228

There is the "Compare" plugin. You can install it via Plugins > Plugin Manager.

Alternatively you can install a specialized file compare software like WinMerge.

9
  • 6
    WinMerge is the way to go (even while being fan of Notepad++)
    – escalator
    Jan 4, 2017 at 10:13
  • 1
    @escalator Yes that is true. I installed both programs and created a NppExec script to start winmerge. If there is a split view, winmerge loads the file from the left view and compares it to the one on the right, with one click in Notepad++. The best of both worlds :) Jan 4, 2017 at 12:19
  • 1
    @LarsFischer That sounds awesome. I managed to download all the plugins and WinMerge. But I don't really know how I would go about the NppExec script to start winmerge. Would you mind sharing your script? We could meet up in a Chat. Thanks.
    – Alex
    Nov 3, 2017 at 10:16
  • 7
    @Alex You would install e.g. WinMerge, then install the NppExec Plugin for Notepad++. Then create a script via Plugins -> NppExec-> Execute ... with this content: npp_console keep npp_save "$(LEFT_VIEW_FILE)" npp_save "$(Right_VIEW_FILE)" npp_run "C:\Program Files (x86)\WinMerge\WinMergeU.exe" "$(LEFT_VIEW_FILE)" "$(Right_VIEW_FILE)" ( four lines) That will run WinMerge with left and right views file (or the current file if only one view is active). Save the script under some name and see stackoverflow.com/a/34611800/4086774 for assigning a shortcut to it. Nov 3, 2017 at 15:29
  • 3
    The OP asked how to do this using Notepad++, many answers diverge.
    – user337598
    Jan 15, 2018 at 14:55
80

Update:

  • for Notepad++ 7.5 and above use Compare v2.0.0
  • for Notepad++ 7.7 and above use Compare v2.0.0 for Notepad++ 7.7, if you need to install manually follow the description below, otherwise use "Plugin Admin".

I use Compare plugin 2 for notepad++ 7.5 and newer versions. Notepad++ 7.5 and newer versions do not have plugin manager. You have to download and install plugins manually. And YES it matters if you use 64bit or 32bit (86x).

So Keep in mind, if you use a 64-bit version of Notepad++, you should also use a 64-bit version of the plugin, and the same is valid for 32-bit.

I wrote a guideline how to install it:

  1. Start your Notepad++ in administrator mode.
  2. Press F1 to find out if your Notepad++ is 64bit or 32bit (86x), hence you need to download the correct plugin version. Download Compare-plugin 2.
  3. Unzip Compare-plugin in a temporary folder.
  4. Import the plugin from the temporary folder.
  5. The plugin should appear under the Plugins menu.

Note:
It is also possible to drag and drop the plugin .dll file directly in the plugin folder.
64bit: %programfiles%\Notepad++\plugins
32bit: %programfiles(x86)%\Notepad++\plugins

Update Thanks to @TylerH for this update: Notepad++ Now has "Plugin Admin" as a replacement for the old Plugin Manager. But this method (answer) is still valid for adding plugins manually for almost any Notepad++ plugins.

Disclaimer: the link to this guideline refer to my personal website.

2
  • 5
    In case it was missed, step 4 import is done via the Settings menu > Import > import plugin(s).
    – SILENT
    May 28, 2019 at 17:11
  • 2
    It's far easier than this. Plugins > Plugin Admin > Tick Compare > Install (V 7.8.4 - 32 bit)
    – JGFMK
    Mar 5, 2020 at 17:10
15

Update (2022-09-22): use the ComparePlus plug-in, and not the outdated Compare plug-in.

enter image description here

Demo:

  1. Open 2 files side-by-side
  2. Plug-ins -> ComparePlus -> Compare:

enter image description here

Features:

enter image description here


The Compare plug-in is no longer maintained:

Compare plugin will not be supported anymore (at least by me) because I consider it obsolete and because (as Peter Jones said) I am working on another plugin - ComparePlus that is Compare plugin’s successor.

For example, the Compare plug-in doesn't show the compared text clearly with dark mode:

enter image description here

10

I give the answer because I need to compare 2 files in notepad++ and there is no option available.

So first enable the plugin manager as asked by question here, Then follow this step to compare 2 files which is free in this software.

1.open notepad++, go to

Plugin -> Plugin Manager -> Show Plugin Manager

2.Show the available plugin list, choose Compare and Install

3.Restart Notepad++.

http://www.technicaloverload.com/compare-two-files-using-notepad/

2
  • 1
    This seems to be the correct answer as it mentions that Notepad++ doesn't come with PluginManager directly and you have to first install that as @Ajay2707 mentioned in that link. This was helpful.
    – OrionMD
    Oct 24, 2018 at 12:00
  • 1
    This is the only answer at linking a solution, how to actually use the plugin.
    – Ister
    Apr 14, 2022 at 12:47
7

Alternatively, you can install "SourceForge Notepad++ Compare Plugin 1.5.6". It provides compare functionality between two files and show the differences between two files.

Link to refer : https://sourceforge.net/projects/npp-compare/files/1.5.6/

3
  • 1
    I believe that this is actually the same plugin that @LarsFischer mentioned
    – Burgi
    May 31, 2016 at 11:44
  • 1
    This is beneficial when you cannot download the plugin because of the access control matter. Oct 20, 2016 at 13:25
  • Only 32-bit seems to not be rebuild recently either, sorry.
    – user337598
    Jan 15, 2018 at 14:59
5

2018 10 25. Update.

Notepad++ 7.5.8 does not have plugin manager by default. You have to download plugins manually.

Keep in mind, if you use 64 bit version of Notepad++, you should also use 64 bit version of plugin. I had a similar issue here.

1
  • Now it has a plugin manager again
    – András
    Jul 4 at 18:12
2

If you are looking for the latest release of Compare, here it is:

https://github.com/pnedev/compare-plugin/releases/latest

0

If you installed Notepad++ with the Plugin Manager then its easy: open notepad++, go to Plugin -> Plugin Manager -> Show Plugin Manager and then search/install the Plugin „compare“. Restart Notepad++

Tutorial: https://youtu.be/8ESbIZbXI7I

If you do not have installed the Plugin Manager:

-Copy the contents of the zip file into Notepad++'s plugins installation folder (%Notepad++_program_folder%\Plugins). use the correct archive version based on your Notepad++ architecture - x86 or x64.

  • restart Notepad++

Not the answer you're looking for? Browse other questions tagged or ask your own question.