You’ll need to redeem your old 16 character keys for both Diablo 2 (and Lord of Destruction if you have it) in order to bind them to your Blizzard account and convert them to the new 26 character keys. Then you’ll need to install the digital download version of both Diablo 2 and the Lord of Destruction expansion.
To redeem/convert your old keys and bind them to your Blizzard account:
From this forum, click your profile name on the upper right, Account settings. Enter the 16 digit key in the “Redeem a code” field. Do this for both your Diablo 2 and LoD keys.
To obtain the new keys:
To get the 26 digit key, click your profile name, Account settings, Games and Subscriptions (left side), scroll down under “Classic Games”, you should see a 26 alphanumeric code to the right of “Diablo II” and another if you also added “Lord of Destruction”. These are the keys you need to copy and paste into each installer.
To download and install the game:
You’ll need to go to the same area where your 26 character keys are located. To the right of the key, you’ll see a download link for both Diablo 2 and Lord of Destruction. Download both of them, install Diablo 2 first, input the new key when prompted, then you’re done. Do the same for LoD.
Note: You may get some weird HTML errors while the downloader is running, also the download will probably go slowly. Just ignore the HTML errors.