This research explored the mechanisms by which time-pressure may influence different knowledge-based behavior, e.g., knowledge sharing and knowledge hiding. Based on the strength model of self-control, we proposed that ego depletion may explain why time-pressure may decrease knowledge sharing and increase knowledge hiding. Moreover, based on the job demandcontrol model, we also proposed that job autonomy would weaken the positive association between time-pressure and ego depletion. To test our hypotheses, we conducted a daily diary study over ten workdays. We recruited 24 employees from a post-graduate class in a university in Myanmar to participate in our study and made 153 observations. We found that time-pressure was associated with increased ego depletion. We also found a positively but marginally significant association between time-pressure and evasive knowledge hiding and playing dumb knowledge hiding. A small negative mediation effect of ego depletion was found on the relationship between time-pressure and knowledge sharing. Moreover, we found a significant moderation effect of job autonomy on the relationship between time-pressure and ego depletion. This study contributes to extant research by exploring for the first time the underlying mechanisms by which time-pressure influences knowledge sharing and clarifying the mixed results found in previous studies of the relationship between time-pressure and knowledge hiding.