I have a motherboard with only one x16 PCIe slot and no x8 slots. I am buying a NIC with very specific configuration, but it is available for x8 slots only. Can I plug a x8 card in a x16 slot? I have googled this question and this seems quite possible. However, I need answer from an expert. Also, are there any performance implications?
What should be: The PCIe spec states that all slots start at 1x/v1.0 and negotiate how many lanes they can use and what clock speed. It shouldn't matter which supports more lanes/clock, some slots are designed to take larger cards and smaller cards fit in larger slots. Whatever the highest spec both sides can communicate at (both the number of lanes and the clock/version), that is the speed that will be negotiated and used. Endpoints can support 1x, 2x, 4x, 8x, 16x, and 32x, though there are no slots specifically for 2x and 32x. Speed is specified by major version number (2.5, 5.0, 8, 16 GT/s).
What really is: Usually what should happen is what actually happens. But there are quite a few boards (especially enthusiast boards) that do not follow spec. Some motherboards will not use anything but a 16x video card in their first PCIe slot. Others will not auto-negotiate correctly (commonly falling back to less lanes - this seems particularly common with 2x cards that negotiate to 1x speed). In server grade hardware these problems are very rare, but it happens. If both the system/motherboard are from the same manufacturer as the card, you should be able to contact their support and find out if it's a supported configuration (if they don't know or can't answer it's a huge redflag and you should consider not buying from them/returning). Also, try searching your particular motherboard and see if anyone has reported a problem.
Yes, you can plug in in and it will work fine.
Any combination of card and slot/connector_on_MB is possible.
A x1 card will work fine in a x1 slot.
A x4 card will work in an x1 slot, but will be limited to x1 speeds.
A x8 card will work in an x1 slot, but will be limited to x1 speeds.
A x16 card will work in an x1 slot, but will be limited to x1 speeds.
There are several kinds of PCIe connectors/slots on motherboards.
The reverse is also possible. If you take a x1 connector and use a saw to open the end of the slot then you can physically connect a larger card and it should work. I know at least one company which does this to put PCIe x16 cards in PCIe x1 slots. (They use the PCIe x16 slots for other cards).