Same instrumentation-amplifier front-end topology, two signals roughly 100 times apart in amplitude.
Both electrocardiography and electroencephalography record electrical activity through surface electrodes on the body, and both rely on the same core front-end building block: a high-common-mode-rejection instrumentation amplifier that pulls a tiny differential biopotential out from underneath much larger common-mode noise. The circuits look similar on a block diagram. What separates them is amplitude. ECG signals measured at the skin run roughly 0.5 to 4 millivolts — large enough that a competent instrumentation amplifier design has real design margin. EEG signals run roughly 10 to 100 microvolts — one to two orders of magnitude smaller — which means an EEG front-end has to hit input-referred noise and input impedance specifications that would be unnecessary, even wasteful, in an ECG design.