High aerosol loadings contribute significantly to the air quality problems of Asian megacities. To address this, monitoring data for aerosol mass and number that is spatially and temoprally of high resolution is needed, while the cost of obtaining such data remains high. Here, we present a field study in a polluted megacity, Beijing, using a diffusion-chargebased electrical aerosol sensor, the Pegasor PPS-M, which is a robust and comparatively low-cost instrument for the monitoring of both aerosol mass and number simultaneously. We present data over several months in the year 2014, and for varying aerosol size distributions, and analyze the performance against particle number and mass (volume) measured using a wide range particle sizer (WPS) and beta-attenuation-based PM2.5 observations. We show that using a single trap voltage, the PPS-M correlates well with particle mass, but not so well with particle number due to the variability in particle size distributions. However, the instrument response to number was improved by running the instrument with a variable trap voltage, and using the ratio of the different signals to gain information on the particle average volume. With this method, we were able to improve the correlation of the PPS-M; with the observed particle number from R = 0.14 to R = 0.72 for the measurement time period. Altogether, the PPS-M instrument displayed robustness and low maintenance requirements, and it showed good correlation with the other instruments in this study.