Most of the time, stock markets seem "random"; they rise one day and then fall the next, and their condition often changes between different trading sessions on the same day. Sometimes this happens due to positive information that leads to a market rise or negative information that leads to a decline.
However, market declines and increases often occur due to the behaviors of speculators. When the market drops to a certain extent, some traders see it as an opportunity to buy, thus entering the market and bringing some movement and rise back to it. Then the opposite happens during a rise when they sell to take profits.