From my observations of my fish in a 6' x 18" x 18" aquarium it seems to me the reason they are fighting is to establish a position in the hierarchy, often called the pecking order. In my experience the more dominant fish are able to compete for food better by pushing others out of the way and getting a larger share. They can then grow bigger and become more dominant. My dominant fish has reached 12" while the subordinates are 10", 8", 8", 8" and 6". I believe the two largest fish are female and the other four are males.
I
Although these fights have sometimes seemed quite violent and lasted up to several days no deaths or serious injuries have resulted in my experience. The fish can be seen sitting next to each other afterwards as though nothing had taken place.
I would agree with this based on observing my clown loaches over the years. Below are just some tales of these battles I've observed in my own tanks over the years.
I had 3 from about 2006?-2018. I started with 5 back in '95, one managed to jump out of the 10g QT tank the first week I had them. Had 4 and then I found one dead in the mid 2000's. I'm actually surprised my clowns lasted that long as I didn't understand nitrates so did water changes once a month and I bet nitrates were in the hundreds.
Anyway, when I had the three, my biggest one (Mama loach) and the next biggest (Papa loach), who was about half her size, would get into spats like that. The smallest one (baby loach, I know not very creative names) would never get faded or spar. I'm sure they did in the early years but my memories have faded.
I have a distinct memory of Mama and baby being in this cave and Papa tried to come in the front and Mama would bite at him several times as he tried to come in. After few minutes, I'm guessing he accepted the dominance and came in the back side of the cave and then they were fine for at least the rest of the day that I was watching.
Sadly, papa jumped out of the tank while I was cleaning the tank in 2018 just a month before I added 4 more smaller loaches and another one I adopted like 3 months after that.
Nowadays, I see more of these faded battles. Mama almost never turns faded. She'll push a loach away with her snout or bite at them if they try to eat a wafer she's eating. The only time I've ever seen her get faded in recent memory is one time she was eating a wafer and all of them were bunch around her and suddenly she went into that faded color and chased everyone away.
I have to admit I got worried about Baby loach bc for like a two week period this summer, he was sparring with this newer loach I call "Lone Survivor.". (I had purchase 3 small loaches from a pet store and two died the next day. She survived. This actually got me into ordering online. I'm pretty sure she's a female as she way bigger than everyone and is maybe 40% of the size of Mama loach in just 4.5 years). LS was battling so much with Baby that she scratched him up pretty good. He had two big scratch marks on his one side. Luckily, there were no ill effects: I did some extra water changes just to help him out. I think Baby finally accepted LS dominance over him. I don't see him battle with LS anymore but now he battles with two of the other loaches (I call them the "Twins" bc they look very similar, though one has a darker vent area, that's the only way I can tell them apart).
In my experience, these battles seem to happen most with the loaches that are similar size.
Again, as Red shark noted, they might battle and then an hour later, you'll see them lying together.