The Nintendo Network ID is the ID that is used to connect with the Nintendo Network on the Wii U console. A Nintendo Network ID can only be created on a Wii U console.
If you have created a Nintendo Network ID, it will be displayed on the Wii U user-selection screen (displayed in orange letters beneath the user's name).
The Nintendo Network is Nintendo's online service which provides online functionality for the Nintendo 3DS and Wii U systems and their compatible games.
So Basically it is to go online on the 3DS and Wii U on the games and you need the ID from Wii U.
Hope this helps!