Skip to main content
CONNECTORS · SERIAL I/O

What Is a DB9 Connector?

A DB9 connector is the nine-pin, D-shaped connector used for RS-232 serial ports on computers and industrial equipment. Its correct name is DE-9, because the nine pins sit in the smaller E-size shell. The same connector also carries RS-422, RS-485 and CAN bus, so the pinout depends on the interface behind it.

01

What a DB9 connector is

A DB9 connector is a nine-pin D-subminiature connector: two rows of contacts, five above four, inside a metal shell shaped like a D so it only fits one way round. It is best known as the COM port on PCs and the RS-232 serial port on instruments, controllers and industrial computers.

Strictly, DB9 is a misnomer. In the original D-sub naming the second letter gives the shell size, and a B shell holds 25 pins. Nine pins fit the smaller E shell, so the correct name is DE-9. The DB9 name stuck through decades of use, and catalogs and datasheets use both terms for the same part.

The male connector has pins and the female has sockets. Two jackscrews either side of the shell screw into threaded posts on the mating half, which stops the plug being pulled or vibrated out. The connector is passive: it sets the mechanical fit and the pin count, while the electronics behind it decide whether the port speaks RS-232, RS-422, RS-485 or CAN.

02

DB9 pinout for RS-232 and CAN bus

Two DB9 pinouts are fixed by standards. The RS-232 assignment for nine-pin ports comes from TIA-574, which IBM popularised on the PC/AT serial port. The CAN bus assignment comes from CAN in Automation (CiA 303-1) and is used on CAN interface cards and many vehicle and machine harnesses.

Pin RS-232 signal Direction at the computer CAN bus (CiA 303-1)
1 DCD, data carrier detect In Reserved
2 RXD, receive data In CAN_L
3 TXD, transmit data Out CAN_GND
4 DTR, data terminal ready Out Reserved
5 GND, signal ground Common Optional shield
6 DSR, data set ready In Optional ground
7 RTS, request to send Out CAN_H
8 CTS, clear to send In Reserved
9 RI, ring indicator In Optional V+

RS-422 and RS-485 have no single DB9 standard. Most industrial computers put the differential pairs on pins 1 to 4 with ground on pin 5, but the exact order differs between manufacturers, so check the manual before wiring a field device. Our explainer on how RS-232 signaling works covers the voltage levels and handshaking lines in more depth.

FAQ · 01
Is a DB9 connector a type of D-sub?
Yes. DB9, or DE-9, is the nine-pin member of the D-sub family, which also includes the 15-pin high-density VGA connector, the 25-pin DB25 and the 37-pin DC-37. All share the D-shaped shell, the jackscrew lock and the one-way fit.
Read the full FAQ —
03

DB9 cables: straight-through vs null modem

A DB9 cable looks the same whichever way it is wired inside, so the label matters. Choose by what sits at each end of the link, then by length and shielding.

  • //
    Straight-through cable. Pin 1 to pin 1, pin 2 to pin 2 and so on. It links a computer (DTE) to a modem or other data set (DCE), which already has its transmit and receive lines the other way round.
  • //
    Null modem cable. Crosses transmit and receive (pins 2 and 3) and the handshake pairs, so two computers, or a computer and a PLC wired as DTE, can talk directly.
  • //
    Gender changer and adapters. A short male-to-male or female-to-female adapter fixes a gender mismatch without changing the wiring.
  • //
    USB to serial adapter. Adds an RS-232 DB9 port to a computer without one. It appears to the operating system as a virtual COM port.
  • //
    Header to DB9 cable. Many industrial boards bring extra COM ports out on a 10-pin header, and a short cable takes each one to a DB9 on the panel or bracket.
04

How far and how fast a DB9 serial link runs

On RS-232, the usual guide is around 15 m at 19.2 kbit/s, set by the cable capacitance the standard allows. Low-capacitance cable and slower baud rates stretch that, and short runs reach 115.2 kbit/s, the highest rate on most PC serial ports. Some industrial serial cards go to 921.6 kbit/s over short leads.

RS-422 and RS-485 use differential pairs on the same connector and run far further, typically up to around 1,200 m at lower data rates, and RS-485 lets many devices share one pair. Over long runs or between buildings, shielded twisted-pair cable and isolated ports stop ground loops and electrical noise from corrupting data.

FAQ · 02
Should a DB9 port be RS-232 or RS-485?
RS-232 suits one device a few meters away, such as a scanner, modem or console. RS-485 suits longer runs and several devices on one bus, such as meters, drives and Modbus RTU networks. Many industrial computers let you set each DB9 port to either mode in the BIOS or with jumpers.
Read the full FAQ —
05

Why industrial computers still have DB9 ports

USB replaced the DB9 on consumer PCs, but serial ports are still specified on new industrial equipment because the devices at the other end are built to last for decades and the protocol is simple to support.

When a computer needs more serial ports than it has built in, serial I/O modules add RS-232, RS-422 or RS-485 channels, often with isolation. Our embedded box PCs and industrial IoT gateways typically include two to six COM ports on DB9 or terminal blocks.

  • //
    PLCs, drives and meters. Modbus RTU and vendor protocols run over RS-232 or RS-485 on factory floors and in substations.
  • //
    Instruments and scanners. Weighing scales, barcode readers, label printers and lab analyzers often offer a DB9 serial port first.
  • //
    Navigation and marine data. GNSS receivers and NMEA 0183 equipment send position and sensor data over serial lines.
  • //
    Console and service ports. Network switches, UPS systems and embedded controllers keep a serial console for set-up when the network is down.
  • //
    Vehicle and machine buses. CAN interfaces on DB9 connect to vehicle, agricultural and mobile machine networks.
06

Quick answers on DB9 connectors

DB9 connectors: common questions

What does DB9 stand for?

D-subminiature, B shell, nine pins. That is how the name reads, although a nine-pin connector actually uses the E shell, which is why the precise name is DE-9.

Is DB9 the same as RS-232?

No. DB9 is the connector and RS-232 is the electrical standard that most often uses it. The same DB9 can carry RS-422, RS-485 or CAN instead, depending on the port.

Is DB9 the same as VGA?

No. VGA uses a 15-pin high-density D-sub in three rows. It shares the shell size with DB9 but has more pins and carries analog video, not serial data.

Is the DB9 on a computer male or female?

Usually male. Computers and other DTE equipment normally have a male DB9 with pins, and modems and DCE equipment a female one. Some devices break the convention, so check before ordering a cable.

Can a DB9 port connect to USB?

Yes, with an adapter. A USB to serial adapter contains a UART chip and appears as a COM port. For industrial use, choose one with a known chipset and driver support for your operating system.

We specify the serial ports a project needs as standard, on the computer or on added serial cards, and set each port’s RS-232, RS-422 or RS-485 mode and termination before the system ships. Send us the devices and cable runs, and we will match the ports and cables to them.