# How do I align this long equation?

I’m not sure I’m understanding what you’re asking for, but is it something like this?

\documentclass{article}
\usepackage{newcomputermodern} % Or your font of choice.

\begin{document}
\begin{aligned} Q_{K_4} &= [l_1,(l_2,l_3),(l_4,l_5),(l_2,l_6,l_4),(l_5,l_6,l_3)].[l_2,l_3,(l_6,l_4),(l_6,l_5)].[l_4,l_6,l_5]\\ &= \cfrac{l_1 (l_2,l_3)(l_4,l_5) (l_2,l_4,l_6)(l_3,l_5,l_6)}{(l_1,(l_2,l_3),( l_4,l_5),(l_2,l_4,l_6),(l_3,l_5,l_6))}. \cfrac{l_2 l_3(l_6,l_4) (l_5,l_6)}{(l_2,l_3(l_6,l_4),(l_6,l_5))}.[l_4,l_5,l_6]\\ &= \cfrac{(l_4,l_5)(l_5,l_6)(l_6,l_4)[l_4,l_5,l_6]l_1 l_2 l_3 ( l_2,l_3 ) (l_2,l_4,l_6) (l_3,l_5,l_6)}{((l_1,l_2,l_3,(l_4,l_5)),(l_2,l_4,l_6,(l_3,l_5,l_6)))(l_2,l_3,l_6,l_4,(l_6,l_5))}\\ &= \cfrac{l_4l_5l_6(l_4,l_5,l_6)l_1l_2l_3(l_2,l_3)(l_2,l_6,l_4)(l_5,l_6,l_3)}{ ((l_1,l_2,l_3,l_4,l_5), (l_2,l_4,l_6, l_3,l_5))(l_2,l_3,l_6,l_4,l_6,l_5)}\\ &\qquad [\ (l_4l_5)(l_5,l_6)(l_6,l_4)[l_4,l_6,l_5] = l_4l_5l_6(l_4,l_5,l_6) ]\\ &= \cfrac{l_1 l_2 l_3 l_4 l_5 l_6 (l_2,l_3)(l_2,l_4,l_6)(l_3,l_5,l_6)(l_4, l_5, l_6)} {((l_1,l_2,l_3,l_4,l_5 ),(l_2,l_3,l_4, l_5,l_6))(l_2,l_3,l_4,l_5,l_6)} \end{aligned}
\end{document}

Using aligned within an equation gets you aligned equations with a single number at the end.

Here is an example that combines aligned with split to give aligned, split equations. I took the liberty of indenting for readability, making outer nested parentheses and brackets larger than the ones they enclose, and changing all the fractions to \frac.

\documentclass{article}
\usepackage{newcomputermodern} % Or your font of choice.

\begin{document}
\begin{aligned} Q_{K_4} &= \begin{split} &[l_1,(l_2,l_3),(l_4,l_5),(l_2,l_6,l_4),(l_5,l_6,l_3)].\\ &\quad[l_2,l_3,(l_6,l_4),(l_6,l_5)].[l_4,l_6,l_5] \end{split}\\ &= \begin{split} &\frac{l_1 (l_2,l_3)(l_4,l_5) (l_2,l_4,l_6)(l_3,l_5,l_6)} {\bigl(l_1,(l_2,l_3),( l_4,l_5),(l_2,l_4,l_6),(l_3,l_5,l_6)\bigr)}.\\ &\quad\frac{l_2 l_3(l_6,l_4) (l_5,l_6)}{\bigl(l_2,l_3(l_6,l_4),(l_6,l_5)\bigr)}.[l_4,l_5,l_6] \end{split}\\ &= \frac{(l_4,l_5)(l_5,l_6)(l_6,l_4)[l_4,l_5,l_6]l_1 l_2 l_3 ( l_2,l_3 ) (l_2,l_4,l_6) (l_3,l_5,l_6)} {\Bigl((l_1,l_2,l_3,(l_4,l_5)\bigr), \bigl(l_2,l_4,l_6,\bigl(l_3,l_5,l_6)\bigr)\Bigr)\bigl(l_2,l_3,l_6,l_4,(l_6,l_5)\bigr)}\\ &= \begin{split} &\frac{l_4l_5l_6(l_4,l_5,l_6)l_1l_2l_3(l_2,l_3)(l_2,l_6,l_4)(l_5,l_6,l_3)} { \bigl((l_1,l_2,l_3,l_4,l_5), (l_2,l_4,l_6, l_3,l_5)\bigr)(l_2,l_3,l_6,l_4,l_6,l_5)}\\ &\quad \bigl[ (l_4l_5)(l_5,l_6)(l_6,l_4)[l_4,l_6,l_5] = l_4l_5l_6(l_4,l_5,l_6) \bigr] \end{split}\\ &= \frac{l_1 l_2 l_3 l_4 l_5 l_6 (l_2,l_3)(l_2,l_4,l_6)(l_3,l_5,l_6)(l_4, l_5, l_6)} {\bigl((l_1,l_2,l_3,l_4,l_5 ),(l_2,l_3,l_4, l_5,l_6)\bigr)(l_2,l_3,l_4,l_5,l_6)} \end{aligned}
\end{document}

Unfortunately you not provide any information about your document. So we don't know the size of \textwidth, used fonts etc. This has strong influence on equation formatting (if there is enough space for equation number or it is necessary to make more breaks):

He case with bigger \textwidth:

\documentclass{article}
\usepackage{geometry} % for bigger \textwidth
\usepackage{mathtools}

\begin{document}
\label{eq:longequation} \begin{aligned} Q_{K_4} & = \bigl[l_1,(l_2,l_3),(l_4,l_5),(l_2,l_6,l_4),(l_5,l_6,l_3)\bigr]{\cdot} \bigl[l_2,l_3,(l_6,l_4),(l_6,l_5)].[l_4,l_6,l_5\bigr] \\ & = \frac{l_1 (l_2,l_3)(l_4,l_5) (l_2,l_4,l_6)(l_3,l_5,l_6)} {\bigl(l_1,(l_2,l_3),( l_4,l_5),(l_2,l_4,l_6),(l_3,l_5,l_6)\bigr)}{\cdot} \frac{l_2 l_3(l_6,l_4) (l_5,l_6)} {\bigl(l_2,l_3(l_6,l_4),(l_6,l_5)\bigr)}{\cdot}[l_4,l_5,l_6] \\ & = \frac{(l_4,l_5)(l_5,l_6)(l_6,l_4)[l_4,l_5,l_6]l_1 l_2 l_3 (l_2,l_3)(l_2,l_4,l_6) (l_3,l_5,l_6)} {\bigl((l_1,l_2,l_3,(l_4,l_5)),(l_2,l_4,l_6,(l_3,l_5,l_6))\bigr) \bigl(l_2,l_3,l_6,l_4,(l_6,l_5)\bigr)} \\ & = \begin{multlined}[t] \frac{l_4l_5l_6(l_4,l_5,l_6)l_1l_2l_3(l_2,l_3)(l_2,l_6,l_4)(l_5,l_6,l_3)} {\bigl((l_1,l_2,l_3,l_4,l_5),(l_2,l_4,l_6, l_3,l_5)\bigr) (l_2,l_3,l_6,l_4,l_6,l_5)}{\cdot}\\ \bigl[(l_4l_5)(l_5,l_6)(l_6,l_4)[l_4,l_6,l_5] = l_4l_5l_6(l_4,l_5,l_6)\bigr] \end{multlined} \\ & = \frac{l_1 l_2 l_3 l_4 l_5 l_6 (l_2,l_3)(l_2,l_4,l_6)(l_3,l_5,l_6)(l_4, l_5, l_6)} {((l_1,l_2,l_3,l_4,l_5 ),(l_2,l_3,l_4, l_5,l_6))(l_2,l_3,l_4,l_5,l_6)} \end{aligned}
\end{document}

A case with smaller (standard article) \textwidth:

\documentclass{article}
%\usepackage{newtxmath}
\usepackage{mathtools}

\begin{document}
\label{eq:longequation} \begin{aligned} Q_{K_4} & = \begin{multlined}[t] \bigl[l_1,(l_2,l_3),(l_4,l_5),(l_2,l_6,l_4),(l_5,l_6,l_3)\bigr]{\cdot} \\ \bigl[l_2,l_3,(l_6,l_4),(l_6,l_5)].[l_4,l_6,l_5\bigr] \end{multlined} \\ & = \begin{multlined}[t] \frac{l_1 (l_2,l_3)(l_4,l_5) (l_2,l_4,l_6)(l_3,l_5,l_6)} {\bigl(l_1,(l_2,l_3),( l_4,l_5),(l_2,l_4,l_6),(l_3,l_5,l_6)\bigr)}{\cdot}\\ \frac{l_2 l_3(l_6,l_4) (l_5,l_6)} {\bigl(l_2,l_3(l_6,l_4),(l_6,l_5)\bigr)}{\cdot}[l_4,l_5,l_6] \end{multlined} \\ & = \frac{(l_4,l_5)(l_5,l_6)(l_6,l_4)[l_4,l_5,l_6]l_1 l_2 l_3 (l_2,l_3)(l_2,l_4,l_6) (l_3,l_5,l_6)} {\bigl((l_1,l_2,l_3,(l_4,l_5)),(l_2,l_4,l_6,(l_3,l_5,l_6))\bigr) \bigl(l_2,l_3,l_6,l_4,(l_6,l_5)\bigr)} \\ & = \begin{multlined}[t] \frac{l_4l_5l_6(l_4,l_5,l_6)l_1l_2l_3(l_2,l_3)(l_2,l_6,l_4)(l_5,l_6,l_3)} {\bigl((l_1,l_2,l_3,l_4,l_5),(l_2,l_4,l_6, l_3,l_5)\bigr) (l_2,l_3,l_6,l_4,l_6,l_5)}{\cdot}\\ \bigl[(l_4l_5)(l_5,l_6)(l_6,l_4)[l_4,l_6,l_5] = l_4l_5l_6(l_4,l_5,l_6)\bigr] \end{multlined} \\ & = \frac{l_1 l_2 l_3 l_4 l_5 l_6 (l_2,l_3)(l_2,l_4,l_6)(l_3,l_5,l_6)(l_4, l_5, l_6)} {((l_1,l_2,l_3,l_4,l_5 ),(l_2,l_3,l_4, l_5,l_6))(l_2,l_3,l_4,l_5,l_6)} \end{aligned}
\end{document}