Can 4051 multiplexers be ganged?

I want to extend the number of both digital and analog pins for a project that uses Arduino Uno. I understand that I can use a 4051 for multiplexing. If I understand correctly I can connect 8 analog lines into the 4051, and one analog line out of the 4051 that is connected to a single analog pin of the Arduino. Then, with 3 DO pins on the Arduino I can select which of the 8 input lines gets passed to the Arduino.

Is it possible to "gang" connect 2 4051's almost in parallel. For example 4051 #1 is connected as described above, with the 4051 selected output connected to Arduino pin A0. Then, 4051 #2 has 8 additional inputs, and the selected output of 4051 #2 is connected to Arduino pin A1. Now I want to use one set of 3 DO pins for selection, and connect these pins to both of the 4051's. An output value of 011 to the DO pins would select line 3 on both of the 4051's.

By this method, I can use only 3 DO pins and select from 16 AI's. I would get an AI selected from each of the 4051's, so both A0 and A1 would have a voltage on the Arduino input, but I will execute an analogRead for the AI that I want and ignore the other.

Will this work?

If so, is there a limit to the number of 4051's that I could gang up in this way?

Yes. it's possible to parallel the select lines, and use one as chip select.
But it's easier to use a 16-channel muxer.


A chip select line is not required, if each 4051 is connected to a different analog input pin.

Depending on the required speed you may consider to use external ADCs with their own multiplexers. Then these ADC can convert the signals in parallel, resulting in a higher sample rate. You also can mount these ADCs closer to your signal sources, to reduce interference.