Make sure that you have the usb cable that came withe the camera.
Then, if you wish, (it is not necessary. but many people like it) Nikon has released Windows 8.1 compatible ViewNX for your camera. The Windows 8.1 compatible versions of these applications may be downloaded from their website.at the link below.
You can also go to the following Nikon link and download and install ViewNX 2 (full version), which is the first in the list.
Due to recent security updates to the Windows operating system and virus protection programs interfere with the camera connections. I have seen many cases where the connection worked one day and would not work the next. Some manual set up may be required to get the camera to connect, even with the Nikon software. See Below
First, restart you computer. Then with the camera on and connected with the usb cable, press the playback or review button on the camera and go to [Start] control panel, ( In Windows 7 select show all options) scanners and cameras and try to connect through the wizard. If unsuccessful, the last place to look is in the device manager. Go to back Control Panel, double click the System icon and select Device Manager. Under the heading Imaging Devices you should find the camera, possibly with a yellow triangle with an exclamation point. Click on Imaging devices (the words will highlight), then go up and click on Action and select "scan for hardware changes". The camera may then appear under the heading. You can also delete it and allow the computer to try to provide the correct driver. If you are try to use the Nikon software, open the program and try to connect.
While not the most popular suggestion, as an alternative, because of multiple compatibility issues with the camera connections and current operating systems, my other suggestion is to get an inexpensive usb memory card reader. You can take your memory card from the camera and plug it into the computer. The card will show up as a removable drive in "My Computer" and you can copy the photo files to a folder on your hard drive and view and print them from Windows or even transfer them from the card into the Nikon software. Personally, I prefer this method due to the simplicity and reduced wear and tear on the camera.
Please keep in mind that my diagnosis & solutions provided are directly dependent on the accuracy of your description of the problem. As with any "do it yourself" fixes, success is a "team effort", since I can't see or touch the camera, and relies on the customer's manual dexterity and ability to follow the instructions well.
If you require additional information, please use the Reply to EXPERT to contact me. Click the ratings only after our exchange is complete and you are satisfied.
If you are satisfied that my answer is accurate or has solved your issue, please do not forget to rate my answer OK, Good or Excellent.