The ecliptic is the path makes through the sky over the course of a year.
The ecliptic is defined in terms of the path of the Sun over a year. It defines the plane in which ‘s orbit lies.
The Earth’s axis of rotation is currently inclined at ##23.5°##. This angle is currently decreasing due to precession.
The celestial equator is defined to be the plane of the Earth’s equator at a particular time. The celestial equator needs to be well defined as it is used to define the positions of stars and other objects. As the Earth’s equatorial plane is rotating due to precession, the celestial equator is defined in terms of its position at an epoch. The J2000 epoch which was at 2000-01-01 12:00:00 is often used.
So, the ecliptic is inclined at an angle of ##23.5°## to the celestial equator due to the Earth’s axial tilt.