Light Dependant Resistor

A photoresistor (also known as a light-dependent resistor, LDR, or photo-conductive cell) is a passive component that decreases resistance with respect to receiving luminosity (light) on the component's sensitive surface.

int sensorPin = A0;
int sensorValue = 0;

void setup() {
  Serial.begin(115200);
}

void loop() {
  sensorValue = analogRead(sensorPin);

  Serial.println(sensorValue);
  
  delay(50);
}

You can use the Arduino IDE Serial plotter to see the changes in real time:

Resources
Sparkfun producto page
Force Sensitive Resistor Hookup Guide

Select a repo